examples(mcp): add ejentum_remote_example (authenticated streamable HTTP MCP)#3497
Closed
ejentum wants to merge 1 commit into
Closed
examples(mcp): add ejentum_remote_example (authenticated streamable HTTP MCP)#3497ejentum wants to merge 1 commit into
ejentum wants to merge 1 commit into
Conversation
…TTP MCP) A new example under examples/mcp/ that connects an Agent to the Ejentum cognitive harness MCP server at https://api.ejentum.com/mcp over the streamable HTTP transport with bearer auth. Adds the two pieces not yet shown in the existing streamable_http_remote_example (DeepWiki, no auth): - Bearer auth via the headers field in MCPServerStreamableHttpParams - An instructions block that tells the agent when to reach for each of the four harness_* scaffold tools (reasoning, code, anti_deception, memory) The demo question is a software-architecture trade-off so the agent has a plausible reason to call harness_reasoning before generating. Signed-off-by: Ejentum <info@ejentum.com>
Member
|
Thanks for sharing this. While we won't have this example within this repo, please feel free to share it in your own repo / resources. |
5 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds a new example under
examples/mcp/ejentum_remote_example/that connects anAgentto the Ejentum cognitive harness MCP server (https://api.ejentum.com/mcp) over the Streamable HTTP transport with bearer auth.The repo already has
streamable_http_remote_example/against DeepWiki. That precedent uses no auth and a single-purpose remote tool surface. This example adds two pieces not yet shown in any existingexamples/mcp/entry:headersinMCPServerStreamableHttpParams. Theheadersfield is documented in the params TypedDict atsrc/agents/mcp/server.pybut no example demonstrates it for an authenticated third-party server.harness_reasoning,harness_code,harness_anti_deception, andharness_memory; the example instructions clarify when each one applies, so the agent's tool-selection trajectory is interpretable.The demo question is a software-architecture trade-off (adding a
NOT NULLcolumn to a 50M-row table) so the agent has a plausible reason to callharness_reasoningbefore generating.Files added
examples/mcp/ejentum_remote_example/main.py(61 lines)examples/mcp/ejentum_remote_example/README.md(26 lines)Two files, ~87 lines, no changes outside the new directory.
Affiliation
I maintain
ejentum-mcp. Submitting this as a teaching example for the auth-headers path; the same shape works for any authenticated streamable-HTTP MCP server, and the README explicitly notes which two lines to change for repointing. Ejentum has free and paid tiers; the README links to the dashboard for a key, not to a checkout flow.Test plan
streamable_http_remote_example(main.py + README.md, sameMCPServerStreamableHttpcontext manager +Runner.run+gen_trace_id/tracepattern).MCPServerStreamableHttpParamsheadersfield as documented insrc/agents/mcp/server.py.uv run(cannot run the full SDK harness in this environment; happy to follow up if CI surfaces an issue).