llama-stack-mirror/llama_stack
Ashwin Bharambe 7c63aebd64
feat(responses)!: add reasoning and annotation added events (#3793)
Implements missing streaming events from OpenAI Responses API spec: 
 - reasoning text/summary events for o1/o3 models, 
 - refusal events for safety moderation
 - annotation events for citations, 
 - and file search streaming events. 
 
Added optional reasoning_content field to chat completion chunks to
support non-standard provider extensions.

**NOTE:** OpenAI does _not_ fill reasoning_content when users use the
chat_completion APIs. This means there is no way for us to implement
Responses (with reasoning) by using OpenAI chat completions! We'd need
to transparently punt to OpenAI's responses endpoints if we wish to do
that. For others though (vLLM, etc.) we can use it.

## Test Plan

File search streaming test passes:
```
./scripts/integration-tests.sh --stack-config server:ci-tests \
   --suite responses --setup gpt --inference-mode replay --pattern test_response_file_search_streaming_events
```

Need more complex setup and validation for reasoning tests (need a vLLM
powered OSS model maybe gpt-oss which can return reasoning_content). I
will do that in a followup PR.
2025-10-11 16:47:14 -07:00
..
apis feat(responses)!: add reasoning and annotation added events (#3793) 2025-10-11 16:47:14 -07:00
cli chore!: remove model mgmt from CLI for Hugging Face CLI (#3700) 2025-10-09 16:50:33 -07:00
core fix(tests): handle TEST_CONTEXT not being set 2025-10-11 15:31:08 -07:00
distributions feat: Add support for Conversations in Responses API (#3743) 2025-10-10 11:57:40 -07:00
models chore: remove dead code (#3729) 2025-10-07 20:26:02 -07:00
providers feat(responses)!: add reasoning and annotation added events (#3793) 2025-10-11 16:47:14 -07:00
strong_typing chore: refactor (chat)completions endpoints to use shared params struct (#3761) 2025-10-10 15:46:34 -07:00
testing fix(testing): improve api_recorder error messages for missing recordings (#3760) 2025-10-09 15:04:16 -07:00
ui chore(ui-deps): bump react-dom and @types/react-dom in /llama_stack/ui (#3693) 2025-10-06 00:02:31 -04:00
__init__.py chore(rename): move llama_stack.distribution to llama_stack.core (#2975) 2025-07-30 23:30:53 -07:00
env.py refactor(test): move tools, evals, datasetio, scoring and post training tests (#1401) 2025-03-04 14:53:47 -08:00
log.py feat: Add support for Conversations in Responses API (#3743) 2025-10-10 11:57:40 -07:00
schema_utils.py fix(auth): allow unauthenticated access to health and version endpoints (#3736) 2025-10-10 13:41:43 -07:00