feat: context compression, integration tests, MCP client#5
Merged
zeroasterisk merged 1 commit intomainfrom Mar 9, 2026
Merged
Conversation
## Context Compression (#80) - ADK.Context.Compressor behaviour with configurable strategies - Truncate strategy: keeps system + last N messages - Summarize strategy: uses LLM to condense older messages - Wired into LlmAgent via context_compressor option - Configurable threshold before compression kicks in ## Integration Tests (#92) - test/integration/gemini_api_test.exs with real Gemini API tests - Single-turn Q&A, multi-turn conversation, tool use round-trip - Agent transfer, error handling (bad model, invalid request) - Tagged @tag :integration, excluded by default - Run with: GEMINI_API_KEY=key mix test --include integration ## MCP Client (#77) - Already implemented in prior PRs with full test coverage - Client connects via stdio, performs JSON-RPC initialization - ToolAdapter converts MCP tools to ADK FunctionTools - Mock MCP server for testing ## Housekeeping - Added examples build artifacts to .gitignore
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.
Context Compression (#80) — P2
ADK.Context.Compressorbehaviour with configurable strategiesADK.Context.Compressor.Truncate— keeps system messages + last N non-system messagesADK.Context.Compressor.Summarize— uses LLM to summarize older messages into condensed historyLlmAgentviacontext_compressoroption — compresses before sending to LLMIntegration Tests (#92) — P1
test/integration/gemini_api_test.exswith 6 test cases hitting real Gemini API@tag :integration, excluded by defaultGEMINI_API_KEY=key mix test --include integrationgemini-2.0-flash-liteto minimize costMCP Client (#77) — Already Complete
ADK.MCP.Clientwith stdio transport, JSON-RPC initialization,list_tools/1,call_tool/3ADK.MCP.ToolAdapterconverts MCP tools to ADKFunctionToolstructstest/support/for testingTests
mix test(excluding integration): 226 tests, 0 failures, 6 excluded