Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
32 changes: 32 additions & 0 deletions .capy/pr-body-cap-2-41193abd.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
## Summary
Migrate Emplode remote model invocation to LiteLLM OpenAI Responses API and set default models to GPT‑5 family with high reasoning effort.

## Changes
- Default model set to `gpt-5`.
- `emplode --fast` now uses `gpt-5-nano`.
- Switched remote (non-local) inference from streaming Chat Completions to the Responses API via LiteLLM, with:
- `reasoning: { effort: "high" }` for both default and fast modes.
- `max_output_tokens` wired to Emplode’s `max_tokens`.
- Custom `run_code` tool defined for function-calling.
- Updated CLI help text and user-facing messages from GPT-4/4o to GPT-5.
- Local mode behavior remains unchanged.

## Nature of change
Enhancement / Refactor (API migration + model defaults).

## Impact
- Non-breaking for local mode.
- Remote mode now uses the Responses API non-streaming flow. Assistant text and any `run_code` tool calls are parsed and executed as before. If streaming is required later, we can enable `stream=True` with the Responses API.
- Azure path continues to work via `model=f"azure/<deployment>"` using the existing environment variables.

## Why
- Align Emplode with the newer OpenAI Responses API through LiteLLM for better support of reasoning settings and future features.
- Standardize on GPT‑5 family and expose a fast option (`gpt-5-nano`) while keeping reasoning quality high.

## Configuration notes
- OPENAI_API_KEY required for OpenAI.
- Optional: `--api_base` for custom OpenAI-compatible backends (uses `custom/<model>` path).
- Azure: `AZURE_API_KEY` or `OPENAI_API_KEY`, `AZURE_API_BASE`, `AZURE_API_VERSION`, `AZURE_DEPLOYMENT_NAME` (wired to Responses API).


₍ᐢ•(ܫ)•ᐢ₎ Generated by [Capy](https://capy.ai) ([view task](https://capy.ai/project/745bca9f-f0c1-4eec-a38c-65f51326313d/task/41193abd-f8aa-4b79-ac4d-8907503cb7cd))
4 changes: 2 additions & 2 deletions emplode/cli.py
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ def cli(emplode):
'--fast',
action='store_true',
default=FAST_MODE,
help='use gpt-4o-mini instead of gpt-4o')
help='use gpt-5-nano instead of gpt-5')
parser.add_argument('-l',
'--local',
action='store_true',
Expand Down Expand Up @@ -103,7 +103,7 @@ def cli(emplode):
if args.yes:
emplode.auto_run = True
if args.fast:
emplode.model = "gpt-4o-mini"
emplode.model = "gpt-5-nano"
if args.local and not args.falcon:

rprint('', Markdown("**Emplode** will use `Code Llama` for local execution."), '')
Expand Down
Loading