You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
feat(api): Add Responses API support for GPT-5.4 and newer models
Implement full OpenAI Responses API streaming for GitHub Copilot models
that exclusively support /responses (e.g. GPT-5.4). Six bugs fixed in
the initial implementation:
- Content type: use input_text/output_text per Responses API spec
- Tool parameters: encode as JSON objects via CodableAny wrapper,
not base64 strings (JSONSerialization.data -> Codable was base64)
- System prompt: include as developer-role messages (was filtered
out during token counting and never re-added)
- Unsupported parameter: remove top_p from Responses requests
- Finish reason: track tool call presence across streaming events
and emit "tool_calls" instead of always "stop", so the orchestrator
actually executes tools instead of treating them as natural completion
- Stream events: handle all 9 Responses API informational event types
(response.created, response.in_progress, function_call_arguments.delta,
etc.) as .ignored instead of throwing DecodingError warnings
API routing: prefer Chat Completions when model supports both endpoints,
only use Responses API when model exclusively supports /responses.
Added truncation and reasoning configuration to ResponsesRequest.
Mermaid diagram improvements:
- Bundle mermaid.min.js locally for offline rendering (no CDN dependency)
- New MermaidWebRenderer: renders via offscreen WKWebView using bundled
engine, respects light/dark theme, proper image sizing
- CachedDiagramView rewritten to use MermaidWebRenderer instead of
inline WKWebView with CDN script tag
- Export/print: diagrams render as high-quality images in PDF, DOCX,
and PPTX instead of showing raw mermaid code
- MermaidDiagramExporter: dedicated exporter for static image capture
using WKNavigationDelegate for reliable completion detection
- Expanded system prompt with 20+ diagram types: state, ER, sankey,
kanban, block, packet, C4 architecture, and syntax correction notes
for commonly misgenerated types (xychart-beta, sankey-beta, etc.)
Version: 20260316.2
Copy file name to clipboardExpand all lines: Resources/whats-new.json
+45Lines changed: 45 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -1,5 +1,50 @@
1
1
{
2
2
"releases": [
3
+
{
4
+
"version": "20260316.2",
5
+
"release_date": "March 16, 2026",
6
+
"introduction": "This release adds support for the latest GPT models, overhauls diagram rendering for better quality and offline use, and fixes several agent reliability issues.",
7
+
"improvements": [
8
+
{
9
+
"id": "gpt-5-4-support",
10
+
"icon": "cpu.fill",
11
+
"title": "GPT-5.4 & New Model Support",
12
+
"description": "SAM now supports GPT-5.4 and other models that use OpenAI's newer Responses API. These models are automatically detected from your GitHub Copilot subscription and work with all of SAM's tools and agent capabilities."
13
+
},
14
+
{
15
+
"id": "mermaid-rendering",
16
+
"icon": "chart.bar.doc.horizontal.fill",
17
+
"title": "Improved Diagram Rendering",
18
+
"description": "Diagrams now render using a bundled engine instead of loading from the internet, so they appear faster and work offline. Rendering respects your light/dark theme setting, and diagrams are properly sized instead of stretching to fill the window."
19
+
},
20
+
{
21
+
"id": "more-diagram-types",
22
+
"icon": "square.grid.3x3.fill",
23
+
"title": "More Diagram Types",
24
+
"description": "SAM can now generate over 20 diagram types including state diagrams, ER diagrams, Sankey flow charts, Kanban boards, packet diagrams, block diagrams, and C4 architecture diagrams - in addition to the existing flowcharts, sequence diagrams, Gantt charts, pie charts, and more."
25
+
},
26
+
{
27
+
"id": "diagram-in-documents",
28
+
"icon": "doc.richtext.fill",
29
+
"title": "Diagrams in Exported Documents",
30
+
"description": "When you export a conversation as PDF, Word, or PowerPoint, any diagrams are now rendered as high-quality images in the document. Previously, exports would show the raw diagram code instead of the rendered visual."
31
+
}
32
+
],
33
+
"bugfixes": [
34
+
{
35
+
"id": "tool-execution-responses-api",
36
+
"icon": "wrench.and.screwdriver.fill",
37
+
"title": "Fixed Agent Tool Execution",
38
+
"description": "Fixed a bug where the agent would recognize tool calls but never execute them when using certain models. The agent now correctly runs tools and continues multi-step workflows on all supported models."
39
+
},
40
+
{
41
+
"id": "system-prompt-responses",
42
+
"icon": "text.bubble.fill",
43
+
"title": "Fixed System Prompt for New Models",
44
+
"description": "System prompts and agent instructions are now correctly sent to all models. Previously, some newer models would ignore the system prompt entirely, leading to generic responses without SAM's personality or capabilities."
0 commit comments