Merge pull request #43 from gabrii/42-remove-unused-code-and-improve-test-coverage
Remove unused code and improve test coverage
This commit is contained in:
@@ -23,12 +23,11 @@ class AzureAdapter:
|
||||
Provides a Completions-compatible interface to the caller by composing a
|
||||
RequestAdapter (pre-request transformations) and a ResponseAdapter
|
||||
(post-request transformations). The adapters receive a reference to this
|
||||
instance for shared per-request state (models/early_response).
|
||||
instance for shared per-request state (models).
|
||||
"""
|
||||
|
||||
# Per-request state (streaming completions only)
|
||||
inbound_model: Optional[str] = None
|
||||
early_response: Optional[Response] = None
|
||||
|
||||
def __init__(self) -> None:
|
||||
"""Initialize child adapters and shared state references."""
|
||||
@@ -42,16 +41,12 @@ class AzureAdapter:
|
||||
|
||||
High-level flow:
|
||||
1) RequestAdapter builds the upstream request kwargs and stores state
|
||||
on this adapter (models) or sets early_response.
|
||||
on this adapter (models).
|
||||
2) Perform the upstream HTTP call using a short-lived requests call.
|
||||
3) ResponseAdapter converts the upstream response into a Flask Response.
|
||||
"""
|
||||
request_kwargs = self.request_adapter.adapt(req)
|
||||
|
||||
# Allow early short-circuit responses (e.g., config errors)
|
||||
if self.early_response is not None:
|
||||
return self.early_response
|
||||
|
||||
record_payload(request_kwargs.get("json", {}), "upstream_request")
|
||||
|
||||
# Perform upstream request with kwargs directly (no long-lived session)
|
||||
@@ -66,7 +61,7 @@ class AzureAdapter:
|
||||
try:
|
||||
resp_content = resp.json()
|
||||
except ValueError:
|
||||
resp_content = resp.content
|
||||
resp_content = resp.text
|
||||
|
||||
body = request_kwargs.get("json", {})
|
||||
if "instructions" in body:
|
||||
|
||||
+15
-118
@@ -6,10 +6,9 @@ requests into Azure Responses API request parameters.
|
||||
|
||||
from __future__ import annotations
|
||||
|
||||
import json
|
||||
from typing import Any, Dict, List, Optional
|
||||
from typing import Any, Dict, List
|
||||
|
||||
from flask import Request, Response, current_app
|
||||
from flask import Request, current_app
|
||||
|
||||
|
||||
class RequestAdapter:
|
||||
@@ -17,9 +16,7 @@ class RequestAdapter:
|
||||
|
||||
Transforms OpenAI Completions/Chat-style inputs into Azure Responses API
|
||||
request parameters suitable for streaming completions in this codebase.
|
||||
Returns request_kwargs for requests.request(**kwargs). If an early
|
||||
short-circuit is needed (for example, missing config), sets
|
||||
self.adapter.early_response and returns an empty dict. Also sets
|
||||
Returns request_kwargs for requests.request(**kwargs). Also sets
|
||||
per-request state on the adapter (model).
|
||||
"""
|
||||
|
||||
@@ -28,40 +25,6 @@ class RequestAdapter:
|
||||
self.adapter = adapter # AzureAdapter instance for shared config/env
|
||||
|
||||
# ---- Helpers (kept local to minimize cross-module coupling) ----
|
||||
def _normalize_call_id(
|
||||
self, original: Optional[str], mapping: Dict[str, str]
|
||||
) -> Optional[str]:
|
||||
"""Return a <=64 char stable call_id.
|
||||
|
||||
- Azure Responses API limits function call ids to 64 chars.
|
||||
- Cursor/OpenAI tool_call ids may exceed that. We map any long ids
|
||||
to a deterministic 64-char hex digest for this request, while
|
||||
preserving pairing between function_call and function_call_output.
|
||||
"""
|
||||
if not original:
|
||||
return original
|
||||
if len(original) <= 64:
|
||||
# Still ensure consistent mapping if we've seen it before
|
||||
return mapping.get(original, original)
|
||||
if original in mapping:
|
||||
return mapping[original]
|
||||
import hashlib
|
||||
|
||||
norm = hashlib.sha256(original.encode("utf-8")).hexdigest() # 64 hex chars
|
||||
mapping[original] = norm
|
||||
return norm
|
||||
|
||||
def _parse_json_body(self, req: Request, body: bytes) -> Optional[Any]:
|
||||
if not body:
|
||||
return None
|
||||
data = req.get_json(silent=True, force=False)
|
||||
if data is not None:
|
||||
return data
|
||||
try:
|
||||
return json.loads(body.decode(req.charset or "utf-8", errors="replace"))
|
||||
except json.JSONDecodeError:
|
||||
return None
|
||||
|
||||
def _copy_request_headers_for_azure(
|
||||
self, src: Request, *, api_key: str
|
||||
) -> Dict[str, str]:
|
||||
@@ -78,51 +41,27 @@ class RequestAdapter:
|
||||
instructions_parts: List[str] = []
|
||||
input_items: List[Dict[str, Any]] = []
|
||||
|
||||
def content_to_text(c: Any) -> str:
|
||||
if c is None:
|
||||
return ""
|
||||
if isinstance(c, str):
|
||||
return c
|
||||
if isinstance(c, list):
|
||||
parts: List[str] = []
|
||||
for it in c:
|
||||
if isinstance(it, dict):
|
||||
if it.get("type") in {"text", "input_text"} and "text" in it:
|
||||
parts.append(str(it.get("text", "")))
|
||||
elif "content" in it and isinstance(it["content"], str):
|
||||
parts.append(it["content"])
|
||||
else:
|
||||
parts.append(str(it))
|
||||
return "\n".join([p for p in parts if p])
|
||||
return json.dumps(c, ensure_ascii=False)
|
||||
|
||||
# Maintain stable mapping of long tool call ids within a single request
|
||||
call_id_map: Dict[str, str] = {}
|
||||
|
||||
for m in messages:
|
||||
role = m.get("role")
|
||||
c = m.get("content")
|
||||
if role in {"system", "developer"}:
|
||||
text = content_to_text(c)
|
||||
text = c
|
||||
if text:
|
||||
instructions_parts.append(text)
|
||||
continue
|
||||
# For user/assistant/tools as inputs
|
||||
if role == "tool":
|
||||
# Map tool outputs back to a normalized call id
|
||||
original_tool_call_id = m.get("tool_call_id")
|
||||
norm_call_id = self._normalize_call_id(
|
||||
original_tool_call_id, call_id_map
|
||||
)
|
||||
call_id = m.get("tool_call_id")
|
||||
|
||||
item = {
|
||||
"type": "function_call_output",
|
||||
"output": content_to_text(c),
|
||||
"output": c,
|
||||
"status": "completed",
|
||||
"call_id": norm_call_id,
|
||||
"call_id": call_id,
|
||||
}
|
||||
input_items.append(item)
|
||||
else:
|
||||
text = content_to_text(c)
|
||||
text = c
|
||||
item = {
|
||||
"role": role or "user",
|
||||
"content": [
|
||||
@@ -137,13 +76,12 @@ class RequestAdapter:
|
||||
if tool_calls := m.get("tool_calls"):
|
||||
for tool_call in tool_calls:
|
||||
function = tool_call.get("function", {})
|
||||
original_id = tool_call.get("id")
|
||||
norm_call_id = self._normalize_call_id(original_id, call_id_map)
|
||||
call_id = tool_call.get("id")
|
||||
item = {
|
||||
"type": "function_call",
|
||||
"name": function.get("name"),
|
||||
"arguments": function.get("arguments"),
|
||||
"call_id": norm_call_id,
|
||||
"call_id": call_id,
|
||||
}
|
||||
input_items.append(item)
|
||||
|
||||
@@ -154,13 +92,8 @@ class RequestAdapter:
|
||||
}
|
||||
|
||||
def _transform_tools_for_responses(self, tools: Any) -> Any:
|
||||
if not isinstance(tools, list):
|
||||
return tools
|
||||
out: List[Dict[str, Any]] = []
|
||||
for t in tools:
|
||||
if not isinstance(t, dict):
|
||||
out.append(t)
|
||||
continue
|
||||
ttype = t.get("type")
|
||||
if ttype == "function" and isinstance(t.get("function"), dict):
|
||||
f = t["function"]
|
||||
@@ -174,48 +107,20 @@ class RequestAdapter:
|
||||
transformed["parameters"] = f["parameters"]
|
||||
transformed["strict"] = False
|
||||
out.append(transformed)
|
||||
else:
|
||||
out.append(t)
|
||||
return out
|
||||
|
||||
def _transform_tool_choice(self, tool_choice: Any) -> Any:
|
||||
if tool_choice in (None, "auto", "none"):
|
||||
return tool_choice
|
||||
if isinstance(tool_choice, dict):
|
||||
t = tool_choice.get("type")
|
||||
if t == "function":
|
||||
fn = tool_choice.get("function") or {}
|
||||
name = fn.get("name")
|
||||
if name:
|
||||
return {"type": "function", "name": name}
|
||||
return tool_choice
|
||||
|
||||
# ---- Main adaptation (always streaming completions-like) ----
|
||||
def adapt(self, req: Request) -> Dict[str, Any]:
|
||||
"""Build requests.request kwargs for the Azure Responses API call.
|
||||
|
||||
Validates the inbound request, sets early_response on error, maps inputs
|
||||
to the Responses schema, and returns a dict suitable for
|
||||
Maps inputs to the Responses schema and returns a dict suitable for
|
||||
requests.request(**kwargs).
|
||||
"""
|
||||
# Reset per-request state
|
||||
self.adapter.inbound_model = None
|
||||
self.adapter.early_response = None
|
||||
|
||||
# Validate method
|
||||
if (req.method or "").upper() != "POST":
|
||||
self.adapter.early_response = Response(
|
||||
"Only POST supported for Azure backend",
|
||||
status=405,
|
||||
mimetype="text/plain",
|
||||
)
|
||||
return {}
|
||||
|
||||
# Parse request body
|
||||
raw_body = req.get_data(cache=True)
|
||||
payload = self._parse_json_body(req, raw_body)
|
||||
if not isinstance(payload, dict):
|
||||
payload = {}
|
||||
payload = req.get_json(silent=True, force=False)
|
||||
|
||||
# Determine target model: prefer env AZURE_MODEL/AZURE_DEPLOYMENT
|
||||
inbound_model = payload.get("model") if isinstance(payload, dict) else None
|
||||
@@ -231,8 +136,6 @@ class RequestAdapter:
|
||||
messages = payload.get("messages") or []
|
||||
tools_in = payload.get("tools") or []
|
||||
tool_choice_in = payload.get("tool_choice")
|
||||
top_p = payload.get("top_p")
|
||||
max_tokens = payload.get("max_tokens") or payload.get("max_output_tokens")
|
||||
prompt_cache_key = payload.get("user") or payload.get("prompt_cache_key")
|
||||
|
||||
mapped = (
|
||||
@@ -251,15 +154,9 @@ class RequestAdapter:
|
||||
# Transform tools and tool choice
|
||||
if tools_in:
|
||||
responses_body["tools"] = self._transform_tools_for_responses(tools_in)
|
||||
mapped_tool_choice = self._transform_tool_choice(tool_choice_in)
|
||||
if mapped_tool_choice is not None:
|
||||
responses_body["tool_choice"] = mapped_tool_choice
|
||||
if tool_choice_in is not None:
|
||||
responses_body["tool_choice"] = tool_choice_in
|
||||
|
||||
# Optional sampling/limits
|
||||
if top_p is not None:
|
||||
responses_body["top_p"] = top_p
|
||||
if max_tokens is not None:
|
||||
responses_body["max_output_tokens"] = max_tokens
|
||||
if prompt_cache_key is not None:
|
||||
responses_body["prompt_cache_key"] = prompt_cache_key
|
||||
|
||||
|
||||
@@ -40,31 +40,6 @@ class ResponseAdapter:
|
||||
alphabet = ascii_letters + digits
|
||||
return "chatcmpl-" + "".join(random.choices(alphabet, k=24))
|
||||
|
||||
@staticmethod
|
||||
def _filter_response_headers(
|
||||
headers: Dict[str, str], *, streaming: bool
|
||||
) -> Dict[str, str]:
|
||||
"""Filter hop-by-hop and incompatible headers for downstream responses."""
|
||||
# Minimal hop-by-hop headers list for downstream filtering
|
||||
hop_by_hop_headers = {
|
||||
"connection",
|
||||
"keep-alive",
|
||||
"proxy-authenticate",
|
||||
"proxy-authorization",
|
||||
"te",
|
||||
"trailers",
|
||||
"transfer-encoding",
|
||||
"upgrade",
|
||||
}
|
||||
out: Dict[str, str] = {}
|
||||
for k, v in headers.items():
|
||||
if k.lower() in hop_by_hop_headers:
|
||||
continue
|
||||
if streaming and k.lower() == "content-length":
|
||||
continue
|
||||
out[k] = v
|
||||
return out
|
||||
|
||||
def _build_completion_chunk(
|
||||
self,
|
||||
*,
|
||||
@@ -91,8 +66,7 @@ class ResponseAdapter:
|
||||
self, obj: Optional[Dict[str, Any]]
|
||||
) -> Iterable[Dict[str, Any]]:
|
||||
"""Handle response.output_item.added events and emit chunks as needed."""
|
||||
if not isinstance(obj, dict):
|
||||
return []
|
||||
|
||||
item_type = obj.get("item", {}).get("type")
|
||||
if item_type == "reasoning":
|
||||
self._thinking = True
|
||||
@@ -142,13 +116,6 @@ class ResponseAdapter:
|
||||
) -> Iterable[Dict[str, Any]]:
|
||||
"""Handle response.function_call.arguments.delta events."""
|
||||
out: list[Dict[str, Any]] = []
|
||||
if self._thinking:
|
||||
out.append(
|
||||
self._build_completion_chunk(
|
||||
delta={"role": "assistant", "content": "</think>\n\n"}
|
||||
)
|
||||
)
|
||||
self._thinking = False
|
||||
arguments_delta = obj.get("delta", "") if isinstance(obj, dict) else ""
|
||||
out.append(
|
||||
self._build_completion_chunk(
|
||||
@@ -223,9 +190,6 @@ class ResponseAdapter:
|
||||
for ev in sse_to_events(
|
||||
upstream_resp.iter_content(chunk_size=8192)
|
||||
):
|
||||
if ev.is_done:
|
||||
# Upstream [DONE] sentinel
|
||||
continue
|
||||
handler_name = "_" + (ev.event or "").replace(
|
||||
"response.", ""
|
||||
).replace(".", "__")
|
||||
@@ -249,11 +213,8 @@ class ResponseAdapter:
|
||||
finally:
|
||||
upstream_resp.close()
|
||||
|
||||
headers = self._filter_response_headers(
|
||||
dict(getattr(upstream_resp, "headers", {})), streaming=True
|
||||
)
|
||||
headers = {}
|
||||
headers["Content-Type"] = "text/event-stream; charset=utf-8"
|
||||
headers.pop("Content-Length", None)
|
||||
headers["Cache-Control"] = "no-cache"
|
||||
headers["Connection"] = "keep-alive"
|
||||
headers["X-Accel-Buffering"] = "no"
|
||||
|
||||
+6
-1
@@ -13,7 +13,11 @@ from rich.traceback import install as install_rich_traceback
|
||||
from .auth import require_auth
|
||||
from .azure.adapter import AzureAdapter
|
||||
from .common.logging import log_request
|
||||
from .common.recording import increment_last_recording, record_payload
|
||||
from .common.recording import (
|
||||
increment_last_recording,
|
||||
init_last_recording,
|
||||
record_payload,
|
||||
)
|
||||
|
||||
blueprint = Blueprint("blueprint", __name__)
|
||||
|
||||
@@ -67,6 +71,7 @@ def catch_all(path: str):
|
||||
returns a 502 JSON error payload.
|
||||
"""
|
||||
log_request(request)
|
||||
init_last_recording()
|
||||
increment_last_recording()
|
||||
record_payload(request.json, "downstream_request")
|
||||
adapter = AzureAdapter()
|
||||
|
||||
+2
-4
@@ -27,9 +27,7 @@ TEST_PATH = os.path.join(PROJECT_ROOT, "tests")
|
||||
)
|
||||
def test(coverage, filter):
|
||||
"""Run the tests."""
|
||||
import pytest
|
||||
|
||||
args = [TEST_PATH, "--verbose"]
|
||||
args = ["pytest", TEST_PATH, "--verbose"]
|
||||
if coverage:
|
||||
args.append("--cov=app")
|
||||
args.append("--cov-branch")
|
||||
@@ -38,7 +36,7 @@ def test(coverage, filter):
|
||||
args.append("--cov-report=term")
|
||||
if filter:
|
||||
args.extend(["-k", filter])
|
||||
rv = pytest.main(args=args)
|
||||
rv = call(args)
|
||||
exit(rv)
|
||||
|
||||
|
||||
|
||||
+43
-98
@@ -13,8 +13,6 @@ from rich.markdown import Markdown
|
||||
from rich.padding import Padding
|
||||
from rich.panel import Panel
|
||||
|
||||
from .sse import SSEEvent
|
||||
|
||||
# Global console instance for consistent logging across modules
|
||||
console = Console()
|
||||
|
||||
@@ -37,7 +35,7 @@ def redact_value(value: str) -> str:
|
||||
if not value:
|
||||
return value
|
||||
if len(value) <= 8:
|
||||
return "***"
|
||||
return "..."
|
||||
return value[:4] + "…" + value[-4:]
|
||||
|
||||
|
||||
@@ -59,37 +57,13 @@ def redact_headers(headers: Dict[str, str]) -> Dict[str, str]:
|
||||
if k.lower() in sensitive:
|
||||
redacted[k] = redact_value(v)
|
||||
else:
|
||||
# Heuristic: mask common bearer/api-key looking values
|
||||
if isinstance(v, str) and (
|
||||
v.startswith("Bearer ") or v.startswith("sk-") or "api_key" in k.lower()
|
||||
):
|
||||
redacted[k] = redact_value(v)
|
||||
else:
|
||||
redacted[k] = v
|
||||
redacted[k] = v
|
||||
return redacted
|
||||
|
||||
|
||||
def multidict_to_dict(md) -> Dict[str, List[str]]:
|
||||
"""Convert a werkzeug MultiDict-like object to a plain dict of lists."""
|
||||
try:
|
||||
return {k: list(vs) for k, vs in md.lists()}
|
||||
except AttributeError:
|
||||
# Fallback for objects without .lists()
|
||||
return {k: [md.get(k)] for k in md.keys()}
|
||||
|
||||
|
||||
def files_summary(req: Request) -> List[Dict[str, Any]]:
|
||||
"""Return a summary of uploaded files from a Flask request."""
|
||||
items: List[Dict[str, Any]] = []
|
||||
for name, storage in req.files.items():
|
||||
items.append(
|
||||
{
|
||||
"field": name,
|
||||
"filename": getattr(storage, "filename", "<unavailable>"),
|
||||
"content_type": getattr(storage, "content_type", "<unknown>"),
|
||||
}
|
||||
)
|
||||
return items
|
||||
return {k: list(vs) for k, vs in md.lists()}
|
||||
|
||||
|
||||
def _capture_request_details(req: Request, request_id: str) -> Dict[str, Any]:
|
||||
@@ -111,7 +85,6 @@ def _capture_request_details(req: Request, request_id: str) -> Dict[str, Any]:
|
||||
"query_args": multidict_to_dict(req.args),
|
||||
"form": multidict_to_dict(req.form),
|
||||
"json": req.get_json(silent=True),
|
||||
"files": files_summary(req),
|
||||
"cookies": req.cookies.to_dict() if req.cookies else {},
|
||||
"headers": redacted_headers,
|
||||
"user_agent": str(req.user_agent) if req.user_agent else "",
|
||||
@@ -163,32 +136,6 @@ def log_request(req: Request) -> str:
|
||||
if messages:
|
||||
console.rule(f"Messages ({len(messages)})")
|
||||
|
||||
def render_content(content: Any) -> str:
|
||||
"""Render a message content value into readable text for logs."""
|
||||
# Show content with actual newlines
|
||||
if content is None:
|
||||
return ""
|
||||
if isinstance(content, bytes):
|
||||
return content.decode("utf-8", errors="replace")
|
||||
if isinstance(content, str):
|
||||
return content
|
||||
if isinstance(content, list):
|
||||
parts: List[str] = []
|
||||
for it in content:
|
||||
if isinstance(it, dict):
|
||||
t = it.get("type")
|
||||
if t == "text" and "text" in it:
|
||||
parts.append(str(it.get("text", "")))
|
||||
elif "content" in it and isinstance(it["content"], str):
|
||||
parts.append(it["content"])
|
||||
else:
|
||||
parts.append(json.dumps(it, ensure_ascii=False, indent=2))
|
||||
else:
|
||||
parts.append(str(it))
|
||||
return "\n".join(p for p in parts if p is not None)
|
||||
# Fallback: pretty JSON
|
||||
return json.dumps(content, ensure_ascii=False, indent=2)
|
||||
|
||||
for idx, msg in enumerate(messages, start=1):
|
||||
role = ""
|
||||
content_val: Any = ""
|
||||
@@ -207,8 +154,7 @@ def log_request(req: Request) -> str:
|
||||
console.print(
|
||||
Padding(
|
||||
Markdown(
|
||||
render_content(content_val)
|
||||
.replace("<", "\n`<")
|
||||
content_val.replace("<", "\n`<")
|
||||
.replace(">", ">`\n")
|
||||
.replace(">`\n\n\n`<", ">`\n\n`<")
|
||||
),
|
||||
@@ -244,46 +190,45 @@ def log_request(req: Request) -> str:
|
||||
return request_id
|
||||
|
||||
|
||||
# --- SSE logging helpers ---
|
||||
# --- SSE logging helpers, keeping for future use if we enable SSE logging ---
|
||||
# from .sse import SSEEvent
|
||||
# def _clean_payload(obj: Any) -> Any:
|
||||
# """Default cleaning to reduce noisy fields in logs.
|
||||
|
||||
# - If obj is a dict, remove top-level 'tools'
|
||||
# - If it contains a nested 'response' dict, also remove its 'tools'
|
||||
# Returns a shallow-cleaned copy when applicable; otherwise returns the input unchanged.
|
||||
# """
|
||||
# if not isinstance(obj, dict):
|
||||
# return obj
|
||||
# # Shallow copy top-level
|
||||
# cleaned = {k: v for k, v in obj.items()}
|
||||
# if "tools" in cleaned:
|
||||
# cleaned = {k: v for k, v in cleaned.items() if k != "tools"}
|
||||
# resp = cleaned.get("response")
|
||||
# if isinstance(resp, dict) and "tools" in resp:
|
||||
# # Shallow copy nested response to drop tools
|
||||
# new_resp = {k: v for k, v in resp.items() if k != "tools"}
|
||||
# cleaned = {**cleaned, "response": new_resp}
|
||||
# return cleaned
|
||||
|
||||
|
||||
def _clean_payload(obj: Any) -> Any:
|
||||
"""Default cleaning to reduce noisy fields in logs.
|
||||
# def log_event(ev: SSEEvent) -> None:
|
||||
# """Pretty-print one SSE event using Rich.
|
||||
|
||||
- If obj is a dict, remove top-level 'tools'
|
||||
- If it contains a nested 'response' dict, also remove its 'tools'
|
||||
Returns a shallow-cleaned copy when applicable; otherwise returns the input unchanged.
|
||||
"""
|
||||
if not isinstance(obj, dict):
|
||||
return obj
|
||||
# Shallow copy top-level
|
||||
cleaned = {k: v for k, v in obj.items()}
|
||||
if "tools" in cleaned:
|
||||
cleaned = {k: v for k, v in cleaned.items() if k != "tools"}
|
||||
resp = cleaned.get("response")
|
||||
if isinstance(resp, dict) and "tools" in resp:
|
||||
# Shallow copy nested response to drop tools
|
||||
new_resp = {k: v for k, v in resp.items() if k != "tools"}
|
||||
cleaned = {**cleaned, "response": new_resp}
|
||||
return cleaned
|
||||
|
||||
|
||||
def log_event(ev: SSEEvent) -> None:
|
||||
"""Pretty-print one SSE event using Rich.
|
||||
|
||||
- Title reflects whether the event had an 'event' name and its index
|
||||
- If payload parses as JSON (ev.json), it is cleaned and printed as JSON; otherwise raw text is printed
|
||||
"""
|
||||
obj = ev.json
|
||||
if obj is not None:
|
||||
title = (
|
||||
f"SSE JSON #{ev.index}" if not ev.event else f"SSE {ev.event} #{ev.index}"
|
||||
)
|
||||
console.print(Panel.fit(title))
|
||||
console.print_json(data=_clean_payload(obj))
|
||||
else:
|
||||
title = f"SSE data #{ev.index}"
|
||||
if ev.event:
|
||||
title = f"SSE {ev.event} #{ev.index}"
|
||||
console.print(Panel.fit(title))
|
||||
console.print(ev.data)
|
||||
# - Title reflects whether the event had an 'event' name and its index
|
||||
# - If payload parses as JSON (ev.json), it is cleaned and printed as JSON; otherwise raw text is printed
|
||||
# """
|
||||
# obj = ev.json
|
||||
# if obj is not None:
|
||||
# title = (
|
||||
# f"SSE JSON #{ev.index}" if not ev.event else f"SSE {ev.event} #{ev.index}"
|
||||
# )
|
||||
# console.print(Panel.fit(title))
|
||||
# console.print_json(data=_clean_payload(obj))
|
||||
# else:
|
||||
# title = f"SSE data #{ev.index}"
|
||||
# if ev.event:
|
||||
# title = f"SSE {ev.event} #{ev.index}"
|
||||
# console.print(Panel.fit(title))
|
||||
# console.print(ev.data)
|
||||
|
||||
+30
-23
@@ -17,29 +17,7 @@ from flask import current_app, has_app_context
|
||||
RECORDINGS_DIR = os.path.join(os.path.dirname(__file__), "..", "..", "recordings")
|
||||
|
||||
# Private, module-level counter tracking the latest recording index.
|
||||
__LAST_RECORDING_INDEX = 0
|
||||
|
||||
# Initialize the counter based on existing subdirectories in the recordings
|
||||
# directory so that subsequent runs continue incrementing from the maximum
|
||||
# observed index.
|
||||
try:
|
||||
entries = os.listdir(RECORDINGS_DIR)
|
||||
except FileNotFoundError:
|
||||
# Create the recordings directory lazily when first used
|
||||
os.makedirs(RECORDINGS_DIR, exist_ok=True)
|
||||
entries = []
|
||||
|
||||
for entry in entries:
|
||||
entry_path = os.path.join(RECORDINGS_DIR, entry)
|
||||
if not os.path.isdir(entry_path):
|
||||
continue
|
||||
try:
|
||||
recording_index = int(entry)
|
||||
if recording_index > __LAST_RECORDING_INDEX:
|
||||
__LAST_RECORDING_INDEX = recording_index
|
||||
except ValueError:
|
||||
# Ignore unrelated folders that do not use a numeric name
|
||||
pass
|
||||
__LAST_RECORDING_INDEX = -1
|
||||
|
||||
|
||||
def config_bypass(func):
|
||||
@@ -57,6 +35,35 @@ def config_bypass(func):
|
||||
return wrapper
|
||||
|
||||
|
||||
@config_bypass
|
||||
def init_last_recording() -> None:
|
||||
"""Initialize the recording index counter.
|
||||
|
||||
Scans existing subdirectories in the recordings directory so that subsequent
|
||||
runs continue incrementing from the maximum observed index.
|
||||
"""
|
||||
global __LAST_RECORDING_INDEX
|
||||
if __LAST_RECORDING_INDEX != -1:
|
||||
return
|
||||
try:
|
||||
entries = os.listdir(RECORDINGS_DIR)
|
||||
except FileNotFoundError:
|
||||
# Create the recordings directory lazily when first used
|
||||
os.makedirs(RECORDINGS_DIR, exist_ok=True)
|
||||
entries = []
|
||||
|
||||
for entry in entries:
|
||||
try:
|
||||
recording_index = int(entry)
|
||||
if recording_index > __LAST_RECORDING_INDEX:
|
||||
__LAST_RECORDING_INDEX = recording_index
|
||||
except ValueError:
|
||||
# Ignore unrelated folders that do not use a numeric name
|
||||
pass
|
||||
if __LAST_RECORDING_INDEX == -1:
|
||||
__LAST_RECORDING_INDEX = 0
|
||||
|
||||
|
||||
@config_bypass
|
||||
def increment_last_recording() -> None:
|
||||
"""Advance the shared recording index for a new request lifecycle."""
|
||||
|
||||
+39
-69
@@ -8,7 +8,7 @@ This module provides helpers to decode and encode SSE streams, including:
|
||||
|
||||
import json
|
||||
from dataclasses import dataclass, field
|
||||
from typing import Any, Dict, Iterable, Iterator, List, Optional, Tuple
|
||||
from typing import Any, Dict, Iterable, Iterator, List, Optional
|
||||
|
||||
from .recording import record_sse
|
||||
|
||||
@@ -86,8 +86,6 @@ class SSEDecoder:
|
||||
retry: Optional[int] = None
|
||||
|
||||
for line in lines:
|
||||
if not line:
|
||||
continue
|
||||
if line.startswith(b"event:"):
|
||||
ev_type = (
|
||||
line.split(b":", 1)[1]
|
||||
@@ -99,22 +97,6 @@ class SSEDecoder:
|
||||
if part.startswith(b" "):
|
||||
part = part[1:]
|
||||
data_parts.append(part)
|
||||
elif line.startswith(b"id:"):
|
||||
val = line.split(b":", 1)[1]
|
||||
if val.startswith(b" "):
|
||||
val = val[1:]
|
||||
ev_id = val.decode(self.encoding, errors="replace")
|
||||
elif line.startswith(b"retry:"):
|
||||
val = line.split(b":", 1)[1]
|
||||
if val.startswith(b" "):
|
||||
val = val[1:]
|
||||
try:
|
||||
retry = int(val.strip())
|
||||
except ValueError:
|
||||
retry = None
|
||||
elif line.startswith(b":"):
|
||||
# Comment line, ignore
|
||||
pass
|
||||
|
||||
data_text = (
|
||||
b"\n".join(data_parts).decode(self.encoding, errors="replace")
|
||||
@@ -168,58 +150,13 @@ def sse_to_events(
|
||||
yield from decoder.end_of_input()
|
||||
|
||||
|
||||
def sse_to_chunks(
|
||||
stream: Iterable[bytes], *, skip_done: bool = True, encoding: str = "utf-8"
|
||||
) -> Iterator[Dict[str, Any]]:
|
||||
"""Convert an SSE byte-stream to an iterator of JSON dicts.
|
||||
|
||||
- Collects multi-line data fields per SSE spec
|
||||
- Uses event.json to avoid repeated json.loads
|
||||
- Skips the [DONE] sentinel by default
|
||||
"""
|
||||
for ev in sse_to_events(stream, encoding=encoding):
|
||||
if skip_done and ev.is_done:
|
||||
continue
|
||||
if ev.json is None:
|
||||
continue
|
||||
yield ev.json
|
||||
|
||||
|
||||
def sse_to_json_events(
|
||||
stream: Iterable[bytes], *, skip_done: bool = True, encoding: str = "utf-8"
|
||||
) -> Iterator[Tuple[Optional[str], Dict[str, Any]]]:
|
||||
"""Yield (event, json_obj) pairs for events whose data parses as JSON.
|
||||
|
||||
Non-JSON events are skipped. The [DONE] sentinel is skipped if skip_done
|
||||
is True.
|
||||
"""
|
||||
for ev in sse_to_events(stream, encoding=encoding):
|
||||
if skip_done and ev.is_done:
|
||||
continue
|
||||
obj = ev.json
|
||||
if obj is None:
|
||||
continue
|
||||
yield (ev.event, obj)
|
||||
|
||||
|
||||
def encode_sse_data(
|
||||
data: str, *, event: Optional[str] = None, id: Optional[str] = None
|
||||
) -> bytes:
|
||||
def encode_sse_data(data: str) -> bytes:
|
||||
"""Encode a single SSE message into bytes.
|
||||
|
||||
If the data contains newlines, they are split into multiple "data:" lines
|
||||
as per the SSE spec. Optionally include event and id.
|
||||
"""
|
||||
out = bytearray()
|
||||
if id is not None:
|
||||
out.extend(b"id: ")
|
||||
out.extend(id.encode("utf-8"))
|
||||
out.extend(b"\n")
|
||||
if event is not None:
|
||||
out.extend(b"event: ")
|
||||
out.extend(event.encode("utf-8"))
|
||||
out.extend(b"\n")
|
||||
|
||||
if data == "":
|
||||
out.extend(b"data:\n")
|
||||
else:
|
||||
@@ -231,12 +168,10 @@ def encode_sse_data(
|
||||
return bytes(out)
|
||||
|
||||
|
||||
def encode_sse_json(
|
||||
obj: Any, *, event: Optional[str] = None, id: Optional[str] = None
|
||||
) -> bytes:
|
||||
def encode_sse_json(obj: Any) -> bytes:
|
||||
"""Encode a Python object as JSON in SSE format and return bytes."""
|
||||
payload = json.dumps(obj, ensure_ascii=False, separators=(",", ":"))
|
||||
return encode_sse_data(payload, event=event, id=id)
|
||||
return encode_sse_data(payload)
|
||||
|
||||
|
||||
def chunks_to_sse(
|
||||
@@ -263,3 +198,38 @@ def chunks_to_sse(
|
||||
def done_event_bytes() -> bytes:
|
||||
"""Return the SSE-encoded [DONE] sentinel as bytes."""
|
||||
return encode_sse_data("[DONE]")
|
||||
|
||||
|
||||
# Keeping for future use if we enable OpenAI backend
|
||||
# def sse_to_chunks(
|
||||
# stream: Iterable[bytes], *, skip_done: bool = True, encoding: str = "utf-8"
|
||||
# ) -> Iterator[Dict[str, Any]]:
|
||||
# """Convert an SSE byte-stream to an iterator of JSON dicts.
|
||||
#
|
||||
# - Collects multi-line data fields per SSE spec
|
||||
# - Uses event.json to avoid repeated json.loads
|
||||
# - Skips the [DONE] sentinel by default
|
||||
# """
|
||||
# for ev in sse_to_events(stream, encoding=encoding):
|
||||
# if skip_done and ev.is_done:
|
||||
# continue
|
||||
# if ev.json is None:
|
||||
# continue
|
||||
# yield ev.json
|
||||
#
|
||||
#
|
||||
# def sse_to_json_events(
|
||||
# stream: Iterable[bytes], *, skip_done: bool = True, encoding: str = "utf-8"
|
||||
# ) -> Iterator[Tuple[Optional[str], Dict[str, Any]]]:
|
||||
# """Yield (event, json_obj) pairs for events whose data parses as JSON.
|
||||
#
|
||||
# Non-JSON events are skipped. The [DONE] sentinel is skipped if skip_done
|
||||
# is True.
|
||||
# """
|
||||
# for ev in sse_to_events(stream, encoding=encoding):
|
||||
# if skip_done and ev.is_done:
|
||||
# continue
|
||||
# obj = ev.json
|
||||
# if obj is None:
|
||||
# continue
|
||||
# yield (ev.event, obj)
|
||||
|
||||
@@ -2,11 +2,11 @@
|
||||
-r prod.txt
|
||||
|
||||
# Testing
|
||||
factory-boy==3.3.3
|
||||
pytest==8.4.2
|
||||
pytest-cov==7.0.0
|
||||
WebTest==3.0.6
|
||||
requests-mock==1.12.1
|
||||
pytest-mock==3.15.1
|
||||
|
||||
# Lint and code style
|
||||
black==25.1.0
|
||||
|
||||
File diff suppressed because one or more lines are too long
@@ -0,0 +1,674 @@
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089146,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"<th"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089146,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"ink"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089146,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":">\n\n"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089146,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"**"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089146,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"Comple"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089146,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"ting"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089146,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" the"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089146,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" changes"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089146,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"**\n\n"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089146,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"I've"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089146,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" ref"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089146,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"act"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089146,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"ored"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089146,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" the"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089147,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" test"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089147,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" class"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089147,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" to"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089147,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" be"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089147,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" extens"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089147,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"ible"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089147,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" using"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089147,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" a"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089147,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" recording"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089147,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" attribute"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089147,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" and"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089147,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" added"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089147,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" helper"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089147,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" methods"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089147,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" for"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089147,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" path"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089147,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" generation"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089147,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"."},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089147,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" I"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089147,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" also"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089147,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" split"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089147,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" the"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089147,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" test"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089147,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" workflow"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089147,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" into"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089147,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" four"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089147,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" private"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089147,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" methods"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089147,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":","},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089147,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" moved"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089147,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" normalize"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089147,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"_response"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089147,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" into"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089147,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" a"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089147,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" private"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089147,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" method"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089147,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" using"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089147,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" re"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089148,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":".sub"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089148,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":","},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089148,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" and"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089148,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" updated"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089148,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" the"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089148,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" test"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089148,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"()"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089148,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" method"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089148,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" to"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089148,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" call"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089148,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" these"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089148,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" helpers"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089148,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"."},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089148,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" Additionally"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089148,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":","},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089148,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" I"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089148,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" added"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089148,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" requests"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089148,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"-m"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089148,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"ock"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089148,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" to"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089148,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" requirements"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089148,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"/dev"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089148,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":".txt"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089148,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"."},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089148,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" Finally"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089148,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":","},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089148,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" I"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089148,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" ran"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089148,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" the"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089148,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" lint"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089148,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" command"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089148,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"—"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089148,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"after"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089148,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" adding"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089148,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" a"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089148,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" doc"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089148,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"string"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089148,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" to"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089148,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" the"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089148,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" test"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089148,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"()"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089148,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" method"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089148,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":","},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089148,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" the"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089149,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" remaining"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089149,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" fl"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089149,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"ake"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089149,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"8"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089149,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" complaint"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089149,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" is"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089149,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" resolved"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089149,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":".\n\n"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089149,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"</"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089149,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"think"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089149,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":">\n\n"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089149,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"Ref"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089149,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"actor"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089149,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" summary"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089149,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":":\n"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089149,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"-"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089149,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" tests"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089149,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"/test"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089149,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"_re"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089149,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"play"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089149,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"_record"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089149,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"ing"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089149,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":".py"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089149,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":":\n"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089149,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" "},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089149,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" -"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089149,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" Added"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089149,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" a"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089149,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" recording"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089149,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":":"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089149,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" str"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089149,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" class"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089150,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" attribute"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089150,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" default"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089150,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"ing"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089150,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" to"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089150,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" \""},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089150,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"ping"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089150,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"\".\n"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089150,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" "},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089150,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" -"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089150,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" Implement"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089150,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"ed"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089150,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" _"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089150,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"get"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089150,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"_request"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089150,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"_path"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089150,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"(kind"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089150,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":")"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089150,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" and"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089150,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" _"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089150,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"get"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089150,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"_response"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089150,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"_path"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089150,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"(kind"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089150,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":").\n"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089150,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" "},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089150,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" -"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089150,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" M"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089150,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"oved"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089150,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" normalize"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089150,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"_response"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089150,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" into"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089150,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" _"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089150,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"normalize"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089150,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"_response"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089150,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" using"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089150,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" re"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089150,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":".sub"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089150,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" as"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089150,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" requested"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089150,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":".\n"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089150,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" "},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089150,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" -"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089151,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" Split"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089151,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" the"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089151,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" test"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089151,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" workflow"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089151,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" into"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089151,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":":\n"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089151,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" "},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089151,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" -"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089151,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" _"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089151,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"mock"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089151,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"_up"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089151,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"stream"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089151,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"\n"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089151,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" "},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089151,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" -"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089151,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" _"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089151,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"perform"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089151,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"_down"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089151,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"stream"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089151,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"_request"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089151,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"\n"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089151,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" "},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089151,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" -"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089151,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" _"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089151,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"verify"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089151,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"_up"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089151,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"stream"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089151,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"_request"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089151,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"\n"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089151,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" "},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089151,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" -"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089151,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" _"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089151,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"verify"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089151,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"_down"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089151,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"stream"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089151,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"_response"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089151,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"\n"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089151,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" "},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089151,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" -"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089151,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" test"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089151,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"()"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089151,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" now"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089151,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" calls"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089151,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" the"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089151,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" four"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089151,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" helper"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089151,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" methods"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089151,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":".\n"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089151,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" "},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089151,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" -"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089151,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" Added"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089151,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" concise"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089152,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" doc"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089152,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"strings"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089152,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":","},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089152,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" including"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089152,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" for"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089152,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" test"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089152,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"(),"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089152,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" to"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089152,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" satisfy"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089152,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" fl"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089152,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"ake"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089152,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"8"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089152,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" D"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089152,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"102"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089152,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":".\n\n"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089152,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"-"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089152,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" requirements"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089152,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"/dev"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089152,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":".txt"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089152,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":":\n"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089152,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" "},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089152,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" -"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089152,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" Added"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089152,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" requests"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089152,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"-m"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089152,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"ock"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089152,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"=="},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089152,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"1"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089152,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"."},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089152,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"12"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089152,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"."},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089152,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"1"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089152,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" under"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089152,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" Testing"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089152,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":".\n\n"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089153,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"What"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089153,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" you"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089153,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" can"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089153,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" do"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089153,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" next"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089153,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":":\n"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089153,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"-"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089153,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" To"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089153,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" run"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089154,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" the"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089154,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" tests"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089154,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" or"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089154,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" extend"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089154,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" to"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089154,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" another"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089154,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" fixture"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089154,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" folder"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089154,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":","},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089154,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" set"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089154,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" Test"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089154,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"Replay"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089154,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"Recording"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089154,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":".record"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089154,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"ing"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089154,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" ="},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089154,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" \"<"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089154,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"your"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089154,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"_sub"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089154,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"dir"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089154,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":">\""},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089154,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" or"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089154,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" subclass"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089154,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" Test"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089154,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"Replay"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089154,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"Recording"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089154,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" and"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089154,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" override"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089154,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" recording"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089154,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":".\n\n"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089154,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"If"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089154,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" you"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089154,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" want"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089154,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":","},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089154,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" I"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089154,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" can"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089154,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":":\n"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089155,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"-"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089155,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" Add"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089155,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" parametr"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089155,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"ization"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089155,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" with"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089155,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" pytest"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089155,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" to"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089155,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" run"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089155,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" the"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089155,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" same"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089155,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" class"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089155,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" against"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089155,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" multiple"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089155,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" recording"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089155,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" sub"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089155,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"directories"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089155,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" automatically"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089155,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":".\n"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089155,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"-"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089155,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" Add"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089155,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" type"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089155,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" hints"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089155,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" for"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089155,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" response"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089155,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" objects"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089155,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" or"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089155,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" further"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089155,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" strengthen"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089155,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" path"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089155,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":" handling"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089155,"model":"gpt-high","choices":[{"index":0,"delta":{"role":"assistant","content":"."},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-BDQIrOwvEPWQIaXKcLQOwq59","object":"chat.completion.chunk","created":1758089156,"model":"gpt-high","choices":[{"index":0,"delta":{},"finish_reason":"stop"}]}
|
||||
|
||||
data: [DONE]
|
||||
|
||||
File diff suppressed because one or more lines are too long
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,396 @@
|
||||
{
|
||||
"model": "gpt-minimal",
|
||||
"temperature": 0,
|
||||
"user": "REDACTED",
|
||||
"messages": [
|
||||
{
|
||||
"role": "system",
|
||||
"content": "REDACTED"
|
||||
},
|
||||
{
|
||||
"role": "user",
|
||||
"content": "REDACTED"
|
||||
},
|
||||
{
|
||||
"role": "user",
|
||||
"content": "REDACTED"
|
||||
}
|
||||
],
|
||||
"tools": [
|
||||
{
|
||||
"type": "function",
|
||||
"function": {
|
||||
"name": "REDACTED",
|
||||
"description": "REDACTED",
|
||||
"parameters": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"explanation": {
|
||||
"type": "string",
|
||||
"description": "REDACTED"
|
||||
},
|
||||
"query": {
|
||||
"type": "string",
|
||||
"description": "REDACTED"
|
||||
},
|
||||
"target_directories": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"type": "string"
|
||||
},
|
||||
"description": "REDACTED"
|
||||
},
|
||||
"search_only_prs": {
|
||||
"type": "boolean",
|
||||
"description": "REDACTED"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"explanation",
|
||||
"query",
|
||||
"target_directories"
|
||||
]
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"type": "function",
|
||||
"function": {
|
||||
"name": "REDACTED",
|
||||
"description": "REDACTED",
|
||||
"parameters": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"command": {
|
||||
"type": "string",
|
||||
"description": "REDACTED"
|
||||
},
|
||||
"is_background": {
|
||||
"type": "boolean",
|
||||
"description": "REDACTED"
|
||||
},
|
||||
"explanation": {
|
||||
"type": "string",
|
||||
"description": "REDACTED"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"command",
|
||||
"is_background"
|
||||
]
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"type": "function",
|
||||
"function": {
|
||||
"name": "REDACTED",
|
||||
"description": "REDACTED",
|
||||
"parameters": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"pattern": {
|
||||
"type": "string",
|
||||
"description": "REDACTED"
|
||||
},
|
||||
"path": {
|
||||
"type": "string",
|
||||
"description": "REDACTED"
|
||||
},
|
||||
"glob": {
|
||||
"type": "string",
|
||||
"description": "REDACTED"
|
||||
},
|
||||
"output_mode": {
|
||||
"type": "string",
|
||||
"description": "REDACTED",
|
||||
"enum": [
|
||||
"content",
|
||||
"files_with_matches",
|
||||
"count"
|
||||
]
|
||||
},
|
||||
"-B": {
|
||||
"type": "number",
|
||||
"description": "REDACTED"
|
||||
},
|
||||
"-A": {
|
||||
"type": "number",
|
||||
"description": "REDACTED"
|
||||
},
|
||||
"-C": {
|
||||
"type": "number",
|
||||
"description": "REDACTED"
|
||||
},
|
||||
"-i": {
|
||||
"type": "boolean",
|
||||
"description": "REDACTED"
|
||||
},
|
||||
"type": {
|
||||
"type": "string",
|
||||
"description": "REDACTED"
|
||||
},
|
||||
"head_limit": {
|
||||
"type": "number",
|
||||
"description": "REDACTED"
|
||||
},
|
||||
"multiline": {
|
||||
"type": "boolean",
|
||||
"description": "REDACTED"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"pattern"
|
||||
]
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"type": "function",
|
||||
"function": {
|
||||
"name": "REDACTED",
|
||||
"description": "REDACTED",
|
||||
"parameters": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"target_file": {
|
||||
"type": "string",
|
||||
"description": "REDACTED"
|
||||
},
|
||||
"explanation": {
|
||||
"type": "string",
|
||||
"description": "REDACTED"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"target_file"
|
||||
]
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"type": "function",
|
||||
"function": {
|
||||
"name": "REDACTED",
|
||||
"description": "REDACTED",
|
||||
"parameters": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"paths": {
|
||||
"description": "REDACTED",
|
||||
"type": "array",
|
||||
"items": {
|
||||
"type": "string"
|
||||
}
|
||||
}
|
||||
},
|
||||
"required": []
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"type": "function",
|
||||
"function": {
|
||||
"name": "REDACTED",
|
||||
"description": "REDACTED",
|
||||
"parameters": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"target_notebook": {
|
||||
"type": "string",
|
||||
"description": "REDACTED"
|
||||
},
|
||||
"cell_idx": {
|
||||
"type": "number",
|
||||
"description": "REDACTED"
|
||||
},
|
||||
"is_new_cell": {
|
||||
"type": "boolean",
|
||||
"description": "REDACTED"
|
||||
},
|
||||
"cell_language": {
|
||||
"type": "string",
|
||||
"description": "REDACTED"
|
||||
},
|
||||
"old_string": {
|
||||
"type": "string",
|
||||
"description": "REDACTED"
|
||||
},
|
||||
"new_string": {
|
||||
"type": "string",
|
||||
"description": "REDACTED"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"target_notebook",
|
||||
"cell_idx",
|
||||
"is_new_cell",
|
||||
"cell_language",
|
||||
"old_string",
|
||||
"new_string"
|
||||
]
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"type": "function",
|
||||
"function": {
|
||||
"name": "REDACTED",
|
||||
"description": "REDACTED",
|
||||
"parameters": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"merge": {
|
||||
"type": "boolean",
|
||||
"description": "REDACTED"
|
||||
},
|
||||
"todos": {
|
||||
"type": "array",
|
||||
"description": "REDACTED",
|
||||
"items": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"content": {
|
||||
"type": "string",
|
||||
"description": "REDACTED"
|
||||
},
|
||||
"status": {
|
||||
"type": "string",
|
||||
"enum": [
|
||||
"pending",
|
||||
"in_progress",
|
||||
"completed",
|
||||
"cancelled"
|
||||
],
|
||||
"description": "REDACTED"
|
||||
},
|
||||
"id": {
|
||||
"type": "string",
|
||||
"description": "REDACTED"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"content",
|
||||
"status",
|
||||
"id"
|
||||
]
|
||||
},
|
||||
"minItems": 2
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"merge",
|
||||
"todos"
|
||||
]
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"type": "function",
|
||||
"function": {
|
||||
"name": "REDACTED",
|
||||
"description": "REDACTED",
|
||||
"parameters": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"target_file": {
|
||||
"type": "string",
|
||||
"description": "REDACTED"
|
||||
},
|
||||
"instructions": {
|
||||
"type": "string",
|
||||
"description": "REDACTED"
|
||||
},
|
||||
"code_edit": {
|
||||
"type": "string",
|
||||
"description": "REDACTED"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"target_file",
|
||||
"instructions",
|
||||
"code_edit"
|
||||
]
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"type": "function",
|
||||
"function": {
|
||||
"name": "REDACTED",
|
||||
"description": "REDACTED",
|
||||
"parameters": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"target_file": {
|
||||
"type": "string",
|
||||
"description": "REDACTED"
|
||||
},
|
||||
"offset": {
|
||||
"type": "integer",
|
||||
"description": "REDACTED"
|
||||
},
|
||||
"limit": {
|
||||
"type": "integer",
|
||||
"description": "REDACTED"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"target_file"
|
||||
]
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"type": "function",
|
||||
"function": {
|
||||
"name": "REDACTED",
|
||||
"description": "REDACTED",
|
||||
"parameters": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"target_directory": {
|
||||
"type": "string",
|
||||
"description": "REDACTED"
|
||||
},
|
||||
"ignore_globs": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"type": "string"
|
||||
},
|
||||
"description": "REDACTED"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"target_directory"
|
||||
]
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"type": "function",
|
||||
"function": {
|
||||
"name": "REDACTED",
|
||||
"description": "REDACTED",
|
||||
"parameters": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"target_directory": {
|
||||
"type": "string",
|
||||
"description": "REDACTED"
|
||||
},
|
||||
"glob_pattern": {
|
||||
"type": "string",
|
||||
"description": "REDACTED"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"glob_pattern"
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
],
|
||||
"tool_choice": "auto",
|
||||
"stream": true
|
||||
}
|
||||
@@ -0,0 +1,10 @@
|
||||
data: {"id":"chatcmpl-ERO7qkefORSgjuOmbThzZoG8","object":"chat.completion.chunk","created":1758093803,"model":"gpt-minimal","choices":[{"index":0,"delta":{"role":"assistant","content":"<think>\n\n"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-ERO7qkefORSgjuOmbThzZoG8","object":"chat.completion.chunk","created":1758093804,"model":"gpt-minimal","choices":[{"index":0,"delta":{"role":"assistant","content":"</think>\n\n"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-ERO7qkefORSgjuOmbThzZoG8","object":"chat.completion.chunk","created":1758093804,"model":"gpt-minimal","choices":[{"index":0,"delta":{"role":"assistant","content":"pong"},"finish_reason":null}]}
|
||||
|
||||
data: {"id":"chatcmpl-ERO7qkefORSgjuOmbThzZoG8","object":"chat.completion.chunk","created":1758093806,"model":"gpt-minimal","choices":[{"index":0,"delta":{},"finish_reason":"stop"}]}
|
||||
|
||||
data: [DONE]
|
||||
|
||||
@@ -0,0 +1,400 @@
|
||||
{
|
||||
"instructions": "REDACTED",
|
||||
"input": [
|
||||
{
|
||||
"role": "user",
|
||||
"content": [
|
||||
{
|
||||
"type": "input_text",
|
||||
"text": "REDACTED"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"role": "user",
|
||||
"content": [
|
||||
{
|
||||
"type": "input_text",
|
||||
"text": "REDACTED"
|
||||
}
|
||||
]
|
||||
}
|
||||
],
|
||||
"model": "gpt-5",
|
||||
"tools": [
|
||||
{
|
||||
"type": "function",
|
||||
"name": "REDACTED",
|
||||
"description": "REDACTED",
|
||||
"parameters": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"explanation": {
|
||||
"type": "string",
|
||||
"description": "REDACTED"
|
||||
},
|
||||
"query": {
|
||||
"type": "string",
|
||||
"description": "REDACTED"
|
||||
},
|
||||
"target_directories": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"type": "string"
|
||||
},
|
||||
"description": "REDACTED"
|
||||
},
|
||||
"search_only_prs": {
|
||||
"type": "boolean",
|
||||
"description": "REDACTED"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"explanation",
|
||||
"query",
|
||||
"target_directories"
|
||||
]
|
||||
},
|
||||
"strict": false
|
||||
},
|
||||
{
|
||||
"type": "function",
|
||||
"name": "REDACTED",
|
||||
"description": "REDACTED",
|
||||
"parameters": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"command": {
|
||||
"type": "string",
|
||||
"description": "REDACTED"
|
||||
},
|
||||
"is_background": {
|
||||
"type": "boolean",
|
||||
"description": "REDACTED"
|
||||
},
|
||||
"explanation": {
|
||||
"type": "string",
|
||||
"description": "REDACTED"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"command",
|
||||
"is_background"
|
||||
]
|
||||
},
|
||||
"strict": false
|
||||
},
|
||||
{
|
||||
"type": "function",
|
||||
"name": "REDACTED",
|
||||
"description": "REDACTED",
|
||||
"parameters": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"pattern": {
|
||||
"type": "string",
|
||||
"description": "REDACTED"
|
||||
},
|
||||
"path": {
|
||||
"type": "string",
|
||||
"description": "REDACTED"
|
||||
},
|
||||
"glob": {
|
||||
"type": "string",
|
||||
"description": "REDACTED"
|
||||
},
|
||||
"output_mode": {
|
||||
"type": "string",
|
||||
"description": "REDACTED",
|
||||
"enum": [
|
||||
"content",
|
||||
"files_with_matches",
|
||||
"count"
|
||||
]
|
||||
},
|
||||
"-B": {
|
||||
"type": "number",
|
||||
"description": "REDACTED"
|
||||
},
|
||||
"-A": {
|
||||
"type": "number",
|
||||
"description": "REDACTED"
|
||||
},
|
||||
"-C": {
|
||||
"type": "number",
|
||||
"description": "REDACTED"
|
||||
},
|
||||
"-i": {
|
||||
"type": "boolean",
|
||||
"description": "REDACTED"
|
||||
},
|
||||
"type": {
|
||||
"type": "string",
|
||||
"description": "REDACTED"
|
||||
},
|
||||
"head_limit": {
|
||||
"type": "number",
|
||||
"description": "REDACTED"
|
||||
},
|
||||
"multiline": {
|
||||
"type": "boolean",
|
||||
"description": "REDACTED"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"pattern"
|
||||
]
|
||||
},
|
||||
"strict": false
|
||||
},
|
||||
{
|
||||
"type": "function",
|
||||
"name": "REDACTED",
|
||||
"description": "REDACTED",
|
||||
"parameters": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"target_file": {
|
||||
"type": "string",
|
||||
"description": "REDACTED"
|
||||
},
|
||||
"explanation": {
|
||||
"type": "string",
|
||||
"description": "REDACTED"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"target_file"
|
||||
]
|
||||
},
|
||||
"strict": false
|
||||
},
|
||||
{
|
||||
"type": "function",
|
||||
"name": "REDACTED",
|
||||
"description": "REDACTED",
|
||||
"parameters": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"paths": {
|
||||
"description": "REDACTED",
|
||||
"type": "array",
|
||||
"items": {
|
||||
"type": "string"
|
||||
}
|
||||
}
|
||||
},
|
||||
"required": []
|
||||
},
|
||||
"strict": false
|
||||
},
|
||||
{
|
||||
"type": "function",
|
||||
"name": "REDACTED",
|
||||
"description": "REDACTED",
|
||||
"parameters": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"target_notebook": {
|
||||
"type": "string",
|
||||
"description": "REDACTED"
|
||||
},
|
||||
"cell_idx": {
|
||||
"type": "number",
|
||||
"description": "REDACTED"
|
||||
},
|
||||
"is_new_cell": {
|
||||
"type": "boolean",
|
||||
"description": "REDACTED"
|
||||
},
|
||||
"cell_language": {
|
||||
"type": "string",
|
||||
"description": "REDACTED"
|
||||
},
|
||||
"old_string": {
|
||||
"type": "string",
|
||||
"description": "REDACTED"
|
||||
},
|
||||
"new_string": {
|
||||
"type": "string",
|
||||
"description": "REDACTED"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"target_notebook",
|
||||
"cell_idx",
|
||||
"is_new_cell",
|
||||
"cell_language",
|
||||
"old_string",
|
||||
"new_string"
|
||||
]
|
||||
},
|
||||
"strict": false
|
||||
},
|
||||
{
|
||||
"type": "function",
|
||||
"name": "REDACTED",
|
||||
"description": "REDACTED",
|
||||
"parameters": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"merge": {
|
||||
"type": "boolean",
|
||||
"description": "REDACTED"
|
||||
},
|
||||
"todos": {
|
||||
"type": "array",
|
||||
"description": "REDACTED",
|
||||
"items": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"content": {
|
||||
"type": "string",
|
||||
"description": "REDACTED"
|
||||
},
|
||||
"status": {
|
||||
"type": "string",
|
||||
"enum": [
|
||||
"pending",
|
||||
"in_progress",
|
||||
"completed",
|
||||
"cancelled"
|
||||
],
|
||||
"description": "REDACTED"
|
||||
},
|
||||
"id": {
|
||||
"type": "string",
|
||||
"description": "REDACTED"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"content",
|
||||
"status",
|
||||
"id"
|
||||
]
|
||||
},
|
||||
"minItems": 2
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"merge",
|
||||
"todos"
|
||||
]
|
||||
},
|
||||
"strict": false
|
||||
},
|
||||
{
|
||||
"type": "function",
|
||||
"name": "REDACTED",
|
||||
"description": "REDACTED",
|
||||
"parameters": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"target_file": {
|
||||
"type": "string",
|
||||
"description": "REDACTED"
|
||||
},
|
||||
"instructions": {
|
||||
"type": "string",
|
||||
"description": "REDACTED"
|
||||
},
|
||||
"code_edit": {
|
||||
"type": "string",
|
||||
"description": "REDACTED"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"target_file",
|
||||
"instructions",
|
||||
"code_edit"
|
||||
]
|
||||
},
|
||||
"strict": false
|
||||
},
|
||||
{
|
||||
"type": "function",
|
||||
"name": "REDACTED",
|
||||
"description": "REDACTED",
|
||||
"parameters": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"target_file": {
|
||||
"type": "string",
|
||||
"description": "REDACTED"
|
||||
},
|
||||
"offset": {
|
||||
"type": "integer",
|
||||
"description": "REDACTED"
|
||||
},
|
||||
"limit": {
|
||||
"type": "integer",
|
||||
"description": "REDACTED"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"target_file"
|
||||
]
|
||||
},
|
||||
"strict": false
|
||||
},
|
||||
{
|
||||
"type": "function",
|
||||
"name": "REDACTED",
|
||||
"description": "REDACTED",
|
||||
"parameters": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"target_directory": {
|
||||
"type": "string",
|
||||
"description": "REDACTED"
|
||||
},
|
||||
"ignore_globs": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"type": "string"
|
||||
},
|
||||
"description": "REDACTED"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"target_directory"
|
||||
]
|
||||
},
|
||||
"strict": false
|
||||
},
|
||||
{
|
||||
"type": "function",
|
||||
"name": "REDACTED",
|
||||
"description": "REDACTED",
|
||||
"parameters": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"target_directory": {
|
||||
"type": "string",
|
||||
"description": "REDACTED"
|
||||
},
|
||||
"glob_pattern": {
|
||||
"type": "string",
|
||||
"description": "REDACTED"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"glob_pattern"
|
||||
]
|
||||
},
|
||||
"strict": false
|
||||
}
|
||||
],
|
||||
"tool_choice": "auto",
|
||||
"prompt_cache_key": "REDACTED",
|
||||
"stream": true,
|
||||
"reasoning": {
|
||||
"effort": "minimal",
|
||||
"summary": "detailed"
|
||||
},
|
||||
"store": false,
|
||||
"stream_options": {
|
||||
"include_obfuscation": false
|
||||
},
|
||||
"truncation": "auto"
|
||||
}
|
||||
File diff suppressed because one or more lines are too long
+74
-49
@@ -6,7 +6,8 @@ See: http://webtest.readthedocs.org/
|
||||
import json
|
||||
import os
|
||||
import re
|
||||
from typing import Any
|
||||
from io import BytesIO
|
||||
from typing import Any, Dict
|
||||
|
||||
from requests_mock import MockerCore
|
||||
from webtest import TestApp
|
||||
@@ -20,28 +21,53 @@ class ReplyBase:
|
||||
"""
|
||||
|
||||
# The subdirectory under tests/recordings/ to load fixtures from
|
||||
recording: str
|
||||
recording: str = "default_recording"
|
||||
upstream_status_code: int = 200
|
||||
expected_downstream_status_code: int = 200
|
||||
|
||||
# Endpoint to mock for the upstream request
|
||||
UPSTREAM_URL = "https://test-resource.openai.azure.com/openai/responses?api-version=2025-04-01-preview"
|
||||
|
||||
def _get_request_path(self, kind: str) -> str:
|
||||
"""Return path for a recorded request JSON of given kind.
|
||||
def _get_recording_path(self, file_name: str) -> str:
|
||||
return os.path.join("tests", "recordings", self.recording, file_name)
|
||||
|
||||
Example: kind="upstream" -> tests/recordings/<recording>/upstream_request.json
|
||||
"""
|
||||
return os.path.join(
|
||||
"tests", "recordings", self.recording, f"{kind}_request.json"
|
||||
)
|
||||
def _get_request_body(self, kind: str) -> str:
|
||||
request_path = self._get_recording_path(f"{kind}_request.json")
|
||||
with open(request_path, "r") as f:
|
||||
return f.read()
|
||||
|
||||
def _get_response_path(self, kind: str) -> str:
|
||||
"""Return path for a recorded response SSE of given kind.
|
||||
def _get_response_body(self, kind: str) -> bytes:
|
||||
response_path = self._get_recording_path(f"{kind}_response.sse")
|
||||
with open(response_path, "rb") as f:
|
||||
return f.read()
|
||||
|
||||
Example: kind="downstream" -> tests/recordings/<recording>/downstream_response.sse
|
||||
"""
|
||||
return os.path.join(
|
||||
"tests", "recordings", self.recording, f"{kind}_response.sse"
|
||||
)
|
||||
@property
|
||||
def expected_upstream_request_body(self) -> str:
|
||||
"""Return recorded upstream request JSON string."""
|
||||
return self._get_request_body("upstream")
|
||||
|
||||
@property
|
||||
def downstream_request_body(self) -> str:
|
||||
"""Return recorded downstream request JSON string."""
|
||||
return self._get_request_body("downstream")
|
||||
|
||||
@property
|
||||
def upstream_response_body(self) -> bytes:
|
||||
"""Return recorded upstream response SSE bytes."""
|
||||
return self._get_response_body("upstream")
|
||||
|
||||
@property
|
||||
def expected_downstream_response_body(self) -> bytes:
|
||||
"""Return recorded downstream response SSE bytes."""
|
||||
return self._get_response_body("downstream")
|
||||
|
||||
@property
|
||||
def downstream_request_headers(self) -> Dict[str, str]:
|
||||
"""Return headers for the downstream request."""
|
||||
return {
|
||||
"Content-Type": "application/json",
|
||||
"Authorization": "Bearer test-service-api-key",
|
||||
}
|
||||
|
||||
def _normalize_response(self, sse_response: bytes) -> str:
|
||||
"""Normalize the response id and created timestamp (use re.sub)."""
|
||||
@@ -52,55 +78,54 @@ class ReplyBase:
|
||||
text = re.sub(r'"created":(\d+)', '"created":1234567890', text)
|
||||
return text
|
||||
|
||||
def _mock_upstream(self, requests_mock: MockerCore) -> Any:
|
||||
def mock_upstream(self, requests_mock: MockerCore) -> Any:
|
||||
"""Mock upstream request with recorded SSE upstream response.
|
||||
|
||||
Returns the mock object so callers can inspect ``last_request``.
|
||||
"""
|
||||
upstream_response_path = self._get_response_path("upstream")
|
||||
return requests_mock.post(
|
||||
self.UPSTREAM_URL,
|
||||
body=open(
|
||||
upstream_response_path, "rb"
|
||||
), # Yes, we need to pass the file object here, not the .read() result
|
||||
status_code=self.upstream_status_code,
|
||||
body=BytesIO(self.upstream_response_body),
|
||||
)
|
||||
|
||||
def _perform_downstream_request(self, testapp: TestApp):
|
||||
def perform_downstream_request(self, testapp: TestApp):
|
||||
"""Perform recorded downstream request and return the response."""
|
||||
downstream_request_path = self._get_request_path("downstream")
|
||||
with open(downstream_request_path, "r") as f:
|
||||
downstream_request = f.read()
|
||||
|
||||
return testapp.post(
|
||||
"/chat/completions",
|
||||
status=200,
|
||||
params=downstream_request,
|
||||
headers={
|
||||
"Content-Type": "application/json",
|
||||
"Authorization": "Bearer test-service-api-key",
|
||||
},
|
||||
status=self.expected_downstream_status_code,
|
||||
params=self.downstream_request_body,
|
||||
headers=self.downstream_request_headers,
|
||||
)
|
||||
|
||||
def _verify_upstream_request(self, mock: Any) -> None:
|
||||
"""Verify upstream request matches the recorded upstream request."""
|
||||
upstream_request_path = self._get_request_path("upstream")
|
||||
with open(upstream_request_path, "r") as f:
|
||||
upstream_request = json.load(f)
|
||||
assert mock.last_request.json() == upstream_request
|
||||
def assert_upstream_request(self, mock: Any) -> None:
|
||||
"""Assert upstream request matches the recorded upstream request."""
|
||||
expected_upstream_request_json = json.loads(self.expected_upstream_request_body)
|
||||
assert mock.last_request.json() == expected_upstream_request_json
|
||||
|
||||
def _verify_downstream_response(self, response) -> None:
|
||||
"""Verify downstream response matches the recorded downstream response."""
|
||||
downstream_response_path = self._get_response_path("downstream")
|
||||
with open(downstream_response_path, "rb") as f:
|
||||
recorded_downstream_response = f.read()
|
||||
def assert_downstream_response(self, response) -> None:
|
||||
"""Assert downstream response matches the recorded downstream response."""
|
||||
response_normalized = self._normalize_response(response.body)
|
||||
recorded_response_normalized = self._normalize_response(
|
||||
recorded_downstream_response
|
||||
expected_response_normalized = self._normalize_response(
|
||||
self.expected_downstream_response_body
|
||||
)
|
||||
assert response_normalized == recorded_response_normalized
|
||||
assert response_normalized == expected_response_normalized
|
||||
|
||||
def modify_settings(self, app) -> None:
|
||||
"""Hook to allow subclasses to tweak app.config before running the test.
|
||||
|
||||
Override in subclasses, e.g.:
|
||||
|
||||
def modify_settings(self, app):
|
||||
app.config["RECORD_TRAFFIC"] = True
|
||||
"""
|
||||
pass
|
||||
|
||||
def test(self, testapp: TestApp, requests_mock: MockerCore):
|
||||
"""Run the replay flow using the configured recording fixtures."""
|
||||
mock = self._mock_upstream(requests_mock)
|
||||
response = self._perform_downstream_request(testapp)
|
||||
self._verify_upstream_request(mock)
|
||||
self._verify_downstream_response(response)
|
||||
self.modify_settings(testapp.app)
|
||||
mock = self.mock_upstream(requests_mock)
|
||||
response = self.perform_downstream_request(testapp)
|
||||
self.assert_upstream_request(mock)
|
||||
self.assert_downstream_response(response)
|
||||
|
||||
@@ -0,0 +1,118 @@
|
||||
"""Functional tests using WebTest.
|
||||
|
||||
See: http://webtest.readthedocs.org/
|
||||
"""
|
||||
|
||||
from .replay_base import ReplyBase
|
||||
|
||||
|
||||
class TestError400(ReplyBase):
|
||||
"""Test a single ping-pong interaction, no tool calls."""
|
||||
|
||||
upstream_status_code = 400
|
||||
expected_downstream_status_code = 400
|
||||
upstream_response_body = b'{"foo": "bar"}'
|
||||
expected_downstream_response_body = b"""
|
||||
Check "azure_response" for the error details:
|
||||
\t{
|
||||
\t "endpoint": "https://t***e.openai.azure.com/openai/responses?api-version=2025-04-01-preview",
|
||||
\t "azure_status_code": 400,
|
||||
\t "azure_response": {
|
||||
\t "foo": "bar"
|
||||
\t },
|
||||
\t "request_body": {
|
||||
\t "instructions": "REDACTE...",
|
||||
\t "input": "...redacted 2 input items...",
|
||||
\t "model": "gpt-5",
|
||||
\t "tools": "...redacted 11 tools...",
|
||||
\t "tool_choice": "auto",
|
||||
\t "prompt_cache_key": "RED***TED",
|
||||
\t "stream": true,
|
||||
\t "reasoning": {
|
||||
\t "effort": "minimal",
|
||||
\t "summary": "detailed"
|
||||
\t },
|
||||
\t "store": false,
|
||||
\t "stream_options": {
|
||||
\t "include_obfuscation": false
|
||||
\t },
|
||||
\t "truncation": "auto"
|
||||
\t }
|
||||
\t}
|
||||
If the issue persists, report it to:
|
||||
\thttps://github.com/gabrii/Cursor-Azure-GPT-5/issues
|
||||
Including all the details above"""
|
||||
|
||||
|
||||
class TestError401(ReplyBase):
|
||||
"""Test a single ping-pong interaction, no tool calls."""
|
||||
|
||||
upstream_status_code = 401
|
||||
expected_downstream_status_code = 400
|
||||
upstream_response_body = b'{"error": "Bad API Key or whatever"}'
|
||||
expected_downstream_response_body = b"""
|
||||
Check "azure_response" for the error details:
|
||||
\t{
|
||||
\t "endpoint": "https://t***e.openai.azure.com/openai/responses?api-version=2025-04-01-preview",
|
||||
\t "azure_status_code": 401,
|
||||
\t "azure_response": {
|
||||
\t "error": "Bad API Key or whatever"
|
||||
\t },
|
||||
\t "request_body": {
|
||||
\t "instructions": "REDACTE...",
|
||||
\t "input": "...redacted 2 input items...",
|
||||
\t "model": "gpt-5",
|
||||
\t "tools": "...redacted 11 tools...",
|
||||
\t "tool_choice": "auto",
|
||||
\t "prompt_cache_key": "RED***TED",
|
||||
\t "stream": true,
|
||||
\t "reasoning": {
|
||||
\t "effort": "minimal",
|
||||
\t "summary": "detailed"
|
||||
\t },
|
||||
\t "store": false,
|
||||
\t "stream_options": {
|
||||
\t "include_obfuscation": false
|
||||
\t },
|
||||
\t "truncation": "auto"
|
||||
\t }
|
||||
\t}
|
||||
If the issue persists, report it to:
|
||||
\thttps://github.com/gabrii/Cursor-Azure-GPT-5/issues
|
||||
Including all the details above"""
|
||||
|
||||
|
||||
class TestError500(ReplyBase):
|
||||
"""Test an error response where the response body is not json."""
|
||||
|
||||
upstream_status_code = 500
|
||||
expected_downstream_status_code = 500
|
||||
upstream_response_body = b"Internal Server Error"
|
||||
expected_downstream_response_body = b"""
|
||||
Check "azure_response" for the error details:
|
||||
\t{
|
||||
\t "endpoint": "https://t***e.openai.azure.com/openai/responses?api-version=2025-04-01-preview",
|
||||
\t "azure_status_code": 500,
|
||||
\t "azure_response": "Internal Server Error",
|
||||
\t "request_body": {
|
||||
\t "instructions": "REDACTE...",
|
||||
\t "input": "...redacted 2 input items...",
|
||||
\t "model": "gpt-5",
|
||||
\t "tools": "...redacted 11 tools...",
|
||||
\t "tool_choice": "auto",
|
||||
\t "prompt_cache_key": "RED***TED",
|
||||
\t "stream": true,
|
||||
\t "reasoning": {
|
||||
\t "effort": "minimal",
|
||||
\t "summary": "detailed"
|
||||
\t },
|
||||
\t "store": false,
|
||||
\t "stream_options": {
|
||||
\t "include_obfuscation": false
|
||||
\t },
|
||||
\t "truncation": "auto"
|
||||
\t }
|
||||
\t}
|
||||
If the issue persists, report it to:
|
||||
\thttps://github.com/gabrii/Cursor-Azure-GPT-5/issues
|
||||
Including all the details above"""
|
||||
@@ -0,0 +1,109 @@
|
||||
"""Tests for click commands defined in app.commands."""
|
||||
|
||||
from click.testing import CliRunner
|
||||
|
||||
import app.commands as commands
|
||||
|
||||
|
||||
def test_test_command_calls_pytest_with_coverage_and_exits(mocker):
|
||||
"""Invoke `test` command with defaults and ensure subprocess call args include coverage."""
|
||||
mock_call = mocker.patch("app.commands.call", return_value=0)
|
||||
|
||||
runner = CliRunner()
|
||||
result = runner.invoke(commands.test)
|
||||
|
||||
assert result.exit_code == 0
|
||||
mock_call.assert_called_once()
|
||||
cmdline = mock_call.call_args[0][0]
|
||||
assert cmdline == [
|
||||
"pytest",
|
||||
commands.TEST_PATH,
|
||||
"--verbose",
|
||||
"--cov=app",
|
||||
"--cov-branch",
|
||||
"--cov-report=xml",
|
||||
"--cov-report=html",
|
||||
"--cov-report=term",
|
||||
]
|
||||
|
||||
|
||||
def test_test_command_no_coverage_and_filter(mocker):
|
||||
"""Invoke `test` with no coverage and a filter; ensure subprocess call args are correct."""
|
||||
mock_call = mocker.patch("app.commands.call", return_value=5)
|
||||
|
||||
runner = CliRunner()
|
||||
result = runner.invoke(commands.test, ["-C", "-k", "unit and not e2e"])
|
||||
|
||||
assert result.exit_code == 5
|
||||
mock_call.assert_called_once()
|
||||
cmdline = mock_call.call_args[0][0]
|
||||
assert cmdline == [
|
||||
"pytest",
|
||||
commands.TEST_PATH,
|
||||
"--verbose",
|
||||
"-k",
|
||||
"unit and not e2e",
|
||||
]
|
||||
|
||||
|
||||
def test_lint_command_invokes_tools_with_expected_order(mocker):
|
||||
"""Invoke `lint` and ensure isort, black, flake8 are called in order."""
|
||||
mock_call = mocker.patch("app.commands.call", return_value=0)
|
||||
|
||||
runner = CliRunner()
|
||||
result = runner.invoke(commands.lint)
|
||||
|
||||
assert result.exit_code == 0
|
||||
# Expect three calls: isort, black, flake8
|
||||
assert mock_call.call_count == 3
|
||||
|
||||
first_cmd = mock_call.call_args_list[0].args[0]
|
||||
second_cmd = mock_call.call_args_list[1].args[0]
|
||||
third_cmd = mock_call.call_args_list[2].args[0]
|
||||
|
||||
assert first_cmd[0] == "isort"
|
||||
assert "--check" not in first_cmd
|
||||
|
||||
assert second_cmd[0] == "black"
|
||||
assert "--check" not in second_cmd
|
||||
|
||||
assert third_cmd[0] == "flake8"
|
||||
|
||||
|
||||
def test_lint_command_check_mode_adds_check_flags(mocker):
|
||||
"""Invoke `lint -c` and ensure --check is added to isort and black only."""
|
||||
mock_call = mocker.patch("app.commands.call", return_value=0)
|
||||
|
||||
runner = CliRunner()
|
||||
result = runner.invoke(commands.lint, ["-c"]) # --check
|
||||
|
||||
assert result.exit_code == 0
|
||||
assert mock_call.call_count == 3
|
||||
|
||||
first_cmd = mock_call.call_args_list[0].args[0]
|
||||
second_cmd = mock_call.call_args_list[1].args[0]
|
||||
third_cmd = mock_call.call_args_list[2].args[0]
|
||||
|
||||
# isort and black should receive --check
|
||||
assert first_cmd[0] == "isort"
|
||||
assert "--check" in first_cmd
|
||||
|
||||
assert second_cmd[0] == "black"
|
||||
assert "--check" in second_cmd
|
||||
|
||||
# flake8 should be called without --check
|
||||
assert third_cmd[0] == "flake8"
|
||||
assert "--check" not in third_cmd
|
||||
|
||||
|
||||
def test_lint_command_exits_on_nonzero_return(mocker):
|
||||
"""Ensure lint exits with the tool's non-zero code and stops after first call."""
|
||||
mock_call = mocker.patch("app.commands.call", return_value=2)
|
||||
|
||||
runner = CliRunner()
|
||||
result = runner.invoke(commands.lint)
|
||||
|
||||
assert result.exit_code == 2
|
||||
assert mock_call.call_count == 1
|
||||
first_cmdline = mock_call.call_args[0][0]
|
||||
assert first_cmdline[0] == "isort"
|
||||
@@ -0,0 +1,35 @@
|
||||
"""Functional tests using WebTest.
|
||||
|
||||
See: http://webtest.readthedocs.org/
|
||||
"""
|
||||
|
||||
import importlib
|
||||
import sys
|
||||
|
||||
import environs
|
||||
|
||||
|
||||
class TestConfig:
|
||||
"""Config."""
|
||||
|
||||
def test_test_config_is_set(self, testapp):
|
||||
"""Ensure that test config is set."""
|
||||
app = testapp.app
|
||||
assert app.config["AZURE_BASE_URL"] != "change_me"
|
||||
assert app.config["AZURE_API_KEY"] != "change_me"
|
||||
|
||||
def test_env_example_loads(self, monkeypatch):
|
||||
"""Patch Env.read_env to read from .env.example and import settings."""
|
||||
orig_read_env = environs.Env.read_env
|
||||
monkeypatch.setattr(
|
||||
environs.Env,
|
||||
"read_env",
|
||||
lambda *args, **kwargs: orig_read_env(
|
||||
".env.example", override=True, **kwargs
|
||||
),
|
||||
)
|
||||
|
||||
sys.modules.pop("app.settings", None)
|
||||
settings = importlib.import_module("app.settings")
|
||||
|
||||
assert settings.AZURE_BASE_URL == "https://change-me.openai.azure.com"
|
||||
@@ -1,26 +0,0 @@
|
||||
"""Functional tests using WebTest.
|
||||
|
||||
See: http://webtest.readthedocs.org/
|
||||
"""
|
||||
|
||||
|
||||
class TestConfig:
|
||||
"""Config."""
|
||||
|
||||
def test_config_is_set(self, testapp):
|
||||
"""Ensure required config values are set."""
|
||||
app = testapp.app
|
||||
assert app.config["AZURE_BASE_URL"] != "change_me"
|
||||
assert app.config["AZURE_API_KEY"] != "change_me"
|
||||
|
||||
|
||||
class TestModels:
|
||||
"""Models."""
|
||||
|
||||
def test_models_endpoint_returns_400(self, testapp):
|
||||
"""Ensure /models endpoint returns HTTP 400."""
|
||||
testapp.get("/models", status=400)
|
||||
|
||||
def test_health_endpoint_returns_200(self, testapp):
|
||||
"""Ensure /health endpoint returns HTTP 200."""
|
||||
testapp.get("/health", status=200)
|
||||
@@ -0,0 +1,51 @@
|
||||
"""Functional tests using WebTest.
|
||||
|
||||
See: http://webtest.readthedocs.org/
|
||||
"""
|
||||
|
||||
from app.common.logging import redact_headers
|
||||
|
||||
from .replay_base import ReplyBase
|
||||
|
||||
|
||||
class TestModelInvalidJson(ReplyBase):
|
||||
"""Test logging of context containing an invalid JSON tool call."""
|
||||
|
||||
recording = "context_tool_call_invalid_json"
|
||||
|
||||
def test(self, testapp, requests_mock, mocker):
|
||||
"""Test logging of context containing an invalid JSON tool call."""
|
||||
console_print = mocker.patch(
|
||||
"rich.console.Console.print", return_value=mocker.Mock()
|
||||
)
|
||||
super().test(testapp, requests_mock)
|
||||
console_print.assert_any_call("[red]Invalid JSON generated by the model:[/red]")
|
||||
|
||||
|
||||
def test_redact_headers():
|
||||
"""Test redacting headers."""
|
||||
headers = {
|
||||
"Authorization": "Bearer test-service-api-key",
|
||||
"authorization": "Bearer test-service-api-key",
|
||||
"non-sensitive": "test-value",
|
||||
"api-key": "", # Empty value
|
||||
"api_key": "short",
|
||||
}
|
||||
redacted_headers = redact_headers(headers)
|
||||
assert redacted_headers == {
|
||||
"Authorization": "Bear…-key",
|
||||
"authorization": "Bear…-key",
|
||||
"non-sensitive": "test-value",
|
||||
"api-key": "",
|
||||
"api_key": "...",
|
||||
}
|
||||
|
||||
|
||||
def test_should_not_refact(mocker):
|
||||
"""Test that headers are not redacted if should_redact is False."""
|
||||
mocker.patch("app.common.logging.should_redact", return_value=False)
|
||||
headers = {
|
||||
"api_key": "test",
|
||||
}
|
||||
redacted_headers = redact_headers(headers)
|
||||
assert redacted_headers == headers
|
||||
@@ -0,0 +1,29 @@
|
||||
"""Functional tests using WebTest.
|
||||
|
||||
See: http://webtest.readthedocs.org/
|
||||
"""
|
||||
|
||||
|
||||
class TestModels:
|
||||
"""Models."""
|
||||
|
||||
def test_models_endpoint_returns_400(self, testapp):
|
||||
"""Ensure /models endpoint returns HTTP 400."""
|
||||
testapp.get("/models", status=400)
|
||||
|
||||
def test_models_endpoint_returns_200(self, testapp):
|
||||
"""Ensure /models endpoint returns HTTP 400."""
|
||||
response = testapp.get(
|
||||
"/models",
|
||||
status=200,
|
||||
headers={"Authorization": "Bearer test-service-api-key"},
|
||||
)
|
||||
content = response.body.decode("utf-8")
|
||||
assert '"gpt-high"' in content
|
||||
assert '"gpt-medium"' in content
|
||||
assert '"gpt-low"' in content
|
||||
assert '"gpt-minimal"' in content
|
||||
|
||||
def test_health_endpoint_returns_200(self, testapp):
|
||||
"""Ensure /health endpoint returns HTTP 200."""
|
||||
testapp.get("/health", status=200)
|
||||
@@ -0,0 +1,76 @@
|
||||
"""Functional tests using WebTest.
|
||||
|
||||
See: http://webtest.readthedocs.org/
|
||||
"""
|
||||
|
||||
import os
|
||||
|
||||
from app.common import recording
|
||||
|
||||
from .replay_base import ReplyBase
|
||||
|
||||
|
||||
class TestRecording(ReplyBase):
|
||||
"""Test different scenarios with traffic recording enabled."""
|
||||
|
||||
def modify_settings(self, app):
|
||||
"""Enables traffic recording."""
|
||||
app.config["RECORD_TRAFFIC"] = True
|
||||
|
||||
def test_multiple_requests(self, testapp, requests_mock, monkeypatch, tmp_path):
|
||||
"""Test two consecutive requests."""
|
||||
monkeypatch.setattr(recording, "RECORDINGS_DIR", tmp_path)
|
||||
monkeypatch.setattr(recording, "__LAST_RECORDING_INDEX", -1)
|
||||
|
||||
super().test(testapp, requests_mock)
|
||||
|
||||
directories = os.listdir(tmp_path)
|
||||
assert len(directories) == 1, "First directory created"
|
||||
|
||||
directory = directories[0]
|
||||
assert directory == "1"
|
||||
assert os.path.exists(
|
||||
os.path.join(tmp_path, directory, "upstream_request.json")
|
||||
)
|
||||
assert os.path.exists(
|
||||
os.path.join(tmp_path, directory, "upstream_response.sse")
|
||||
)
|
||||
assert os.path.exists(
|
||||
os.path.join(tmp_path, directory, "downstream_request.json")
|
||||
)
|
||||
assert os.path.exists(
|
||||
os.path.join(tmp_path, directory, "downstream_response.sse")
|
||||
)
|
||||
|
||||
super().test(testapp, requests_mock)
|
||||
|
||||
directories = os.listdir(tmp_path)
|
||||
assert len(directories) == 2, "Second directory created"
|
||||
|
||||
def test_creates_folder(self, testapp, requests_mock, monkeypatch, tmp_path):
|
||||
"""Test recordings folder is created."""
|
||||
recordings_path = os.path.join(tmp_path, "recordings")
|
||||
monkeypatch.setattr(recording, "RECORDINGS_DIR", recordings_path)
|
||||
monkeypatch.setattr(recording, "__LAST_RECORDING_INDEX", -1)
|
||||
|
||||
assert not os.path.exists(recordings_path)
|
||||
|
||||
super().test(testapp, requests_mock)
|
||||
|
||||
assert os.path.exists(recordings_path)
|
||||
assert os.path.exists(os.path.join(recordings_path, "1"))
|
||||
|
||||
def test_increments_index(self, testapp, requests_mock, monkeypatch, tmp_path):
|
||||
"""Test that the index for the next recording is incremented, and ignores unrelated folders."""
|
||||
monkeypatch.setattr(recording, "RECORDINGS_DIR", tmp_path)
|
||||
monkeypatch.setattr(recording, "__LAST_RECORDING_INDEX", -1)
|
||||
|
||||
# Last recording index 123
|
||||
os.makedirs(os.path.join(tmp_path, "123"))
|
||||
|
||||
# Unrelated folder
|
||||
os.makedirs(os.path.join(tmp_path, "foo"))
|
||||
|
||||
super().test(testapp, requests_mock)
|
||||
|
||||
assert os.path.exists(os.path.join(tmp_path, "124"))
|
||||
@@ -15,7 +15,7 @@ class TestOnePingPong(ReplyBase):
|
||||
class TestMultiplePingPongs(ReplyBase):
|
||||
"""Test multiple ping-pong interactions back and forth, no tool calls."""
|
||||
|
||||
recording = "one_ping_pong"
|
||||
recording = "multiple_ping_pongs"
|
||||
|
||||
|
||||
class TestContextWithSingleToolCalls(ReplyBase):
|
||||
|
||||
Reference in New Issue
Block a user