Skip to content

Commit 47938d5

Browse files
[AiBundle] Display tool JSON schema in profiler Platform Calls
Previously, the profiler only showed tool names in Platform Calls > Options > tools. This made it difficult to debug dynamically enriched tools since the actual JSON schema sent to the API was not visible. This change: - Displays tool JSON schema using dump() for interactive exploration - Adds a "Copy JSON Schema" button to copy the schema to clipboard
1 parent cc7b3f8 commit 47938d5

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

src/ai-bundle/templates/data_collector.html.twig

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -143,7 +143,13 @@
143143
<li>{{ key }}:
144144
<ul>
145145
{% for tool in value %}
146-
<li>{{ tool.name }}</li>
146+
<li>
147+
<strong>{{ tool.name }}</strong>
148+
{% if tool.parameters %}
149+
<button class="btn btn-sm hidden" data-clipboard-text="{{ tool.parameters|json_encode|e('html_attr') }}">Copy JSON Schema</button>
150+
{{ dump(tool.parameters) }}
151+
{% endif %}
152+
</li>
147153
{% endfor %}
148154
</ul>
149155
</li>

0 commit comments

Comments
 (0)