eino-ext

module
v0.0.0-...-3309b9d Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 14, 2026 License: MIT

README

eino-ext

Some Eino extentions

Directories

Path Synopsis
callbacks
activity
Package activity exposes a Kilocode-style live "activity" stream of what agents, LLMs and tools are doing during an eino run, suitable for fan-out to a UI over SSE (or any other transport).
Package activity exposes a Kilocode-style live "activity" stream of what agents, LLMs and tools are doing during an eino run, suitable for fan-out to a UI over SSE (or any other transport).
activity/metrics
Package metrics provides an optional Prometheus collector for the activity package: it subscribes to a Bus session and, on step.ended events, records per-model/agent token and cost counters.
Package metrics provides an optional Prometheus collector for the activity package: it subscribes to a Bus session and, on step.ended events, records per-model/agent token and cost counters.
activity/sse
Package sse fans an activity.Bus out over HTTP Server-Sent Events using Hertz.
Package sse fans an activity.Bus out over HTTP Server-Sent Events using Hertz.
log
Package log provides a callbacks.Handler that logs eino component lifecycle events via logrus with structured fields, making it easy to inspect agent execution in production and development.
Package log provides a callbacks.Handler that logs eino component lifecycle events via logrus with structured fields, making it easy to inspect agent execution in production and development.
oteltrace
Package oteltrace provides a callbacks.Handler that records OpenTelemetry spans for eino component lifecycle: a span per chat-model generate (with token-usage attributes) and a span per tool call (with name + error attributes).
Package oteltrace provides a callbacks.Handler that records OpenTelemetry spans for eino component lifecycle: a span per chat-model generate (with token-usage attributes) and a span per tool call (with name + error attributes).
components
agent/memory/file
Package file provides a simple JSONL-backed MemoryStore implementation.
Package file provides a simple JSONL-backed MemoryStore implementation.
agent/memory/opensearch
Package opensearch provides an OpenSearch-backed implementation of the MemoryStore interface for persistent, production-grade agent memory storage with BM25 text search and optional kNN vector search via eino's indexer/opensearch and retriever/opensearch components.
Package opensearch provides an OpenSearch-backed implementation of the MemoryStore interface for persistent, production-grade agent memory storage with BM25 text search and optional kNN vector search via eino's indexer/opensearch and retriever/opensearch components.
agent/profilesupervisor
Package profilesupervisor provides a profile supervisor agent factory that dynamically selects, at runtime, the sub-agent whose shell sandbox uses the right OCI base image for the task.
Package profilesupervisor provides a profile supervisor agent factory that dynamically selects, at runtime, the sub-agent whose shell sandbox uses the right OCI base image for the task.
document/transformer/prune
Package prune provides a document.Transformer that removes documents whose trimmed content is below a configurable minimum length.
Package prune provides a document.Transformer that removes documents whose trimmed content is below a configurable minimum length.
indexer/opensearch
Package opensearch provides an Indexer implementation backed by OpenSearch, plus supporting utilities for index lifecycle management (field mapping merges, source-hash lookups, bulk reconciliation).
Package opensearch provides an Indexer implementation backed by OpenSearch, plus supporting utilities for index lifecycle management (field mapping merges, source-hash lookups, bulk reconciliation).
memory/examples/contextopt_persistent command
Command contextopt_persistent demonstrates how to combine the cross-request session condenser (components/memory/session) with the intra-run context optimizer (components/middleware/contextopt) WITHOUT paying the LLM summarization cost twice.
Command contextopt_persistent demonstrates how to combine the cross-request session condenser (components/memory/session) with the intra-run context optimizer (components/middleware/contextopt) WITHOUT paying the LLM summarization cost twice.
memory/runner
Package runner bridges an eino adk.Runner run to the cross-request session lifecycle (session.Turn) so that any eino project gets streaming + history persistence out of the box, without re-implementing the glue per project.
Package runner bridges an eino adk.Runner run to the cross-request session lifecycle (session.Turn) so that any eino project gets streaming + history persistence out of the box, without re-implementing the glue per project.
memory/session
Package session provides the generic, cross-request lifecycle for persisting a conversation history on top of a memory.Memory store.
Package session provides the generic, cross-request lifecycle for persisting a conversation history on top of a memory.Memory store.
middleware/agentattr
Package agentattr provides an adk.ChatModelAgentMiddleware that attributes the callbacks/activity event stream to a named agent.
Package agentattr provides an adk.ChatModelAgentMiddleware that attributes the callbacks/activity event stream to a named agent.
middleware/contextopt
Package contextopt provides context-window optimization strategies (inspired by kilocode's session compaction) for the eino ecosystem.
Package contextopt provides context-window optimization strategies (inspired by kilocode's session compaction) for the eino ecosystem.
middleware/promptenhance
Package promptenhance provides an ADK middleware that enhances user prompts through a small model and optionally asks for human approval before sending the enhanced version to the supervisor.
Package promptenhance provides an ADK middleware that enhances user prompts through a small model and optionally asks for human approval before sending the enhanced version to the supervisor.
middleware/safety
Package safety provides an adk.ChatModelAgentMiddleware that enforces a safety control layer around LLM tool invocations.
Package safety provides an adk.ChatModelAgentMiddleware that enforces a safety control layer around LLM tool invocations.
model/cachestab
Package cachestab provides a deterministic, non-destructive normalization of tool definitions to maximize prompt-cache stability (port of headroom's tool_def_normalize).
Package cachestab provides a deterministic, non-destructive normalization of tool definitions to maximize prompt-cache stability (port of headroom's tool_def_normalize).
model/chatmodel
Package chatmodel provides a provider-generic factory for constructing an eino model.ToolCallingChatModel from a single, additive Config.
Package chatmodel provides a provider-generic factory for constructing an eino model.ToolCallingChatModel from a single, additive Config.
model/copilot
Package copilot provides a GitHub Copilot provider implementation.
Package copilot provides a GitHub Copilot provider implementation.
prompt
Package prompt provides a base of solid system prompts by type, extensible per project.
Package prompt provides a base of solid system prompts by type, extensible per project.
tool/github
Package github provides eino tools that interact with GitHub repositories, issues, pull requests, releases, branches, and webhooks.
Package github provides eino tools that interact with GitHub repositories, issues, pull requests, releases, branches, and webhooks.
tool/opensearch_retriever
Package opensearch_retriever provides a generic tool.InvokableTool that wraps the existing OpenSearch retriever, enabling semantic document search via natural-language queries as an invokable tool.
Package opensearch_retriever provides a generic tool.InvokableTool that wraps the existing OpenSearch retriever, enabling semantic document search via natural-language queries as an invokable tool.
tool/shell
Package shell provides an eino shell tool backed by the Dagger engine.
Package shell provides an eino shell tool backed by the Dagger engine.
tool/websearch
Package websearch provides eino tools for DuckDuckGo web search and URL fetching with anti-bot mitigations (cookie jar, browser headers, session warm-up), HTML-to-Markdown conversion, and SSRF protection.
Package websearch provides eino tools for DuckDuckGo web search and URL fetching with anti-bot mitigations (cookie jar, browser headers, session warm-up), HTML-to-Markdown conversion, and SSRF protection.
libs
contentcomp
Package contentcomp defines the shared, dependency-free contracts used by the deterministic per-message content compressors (jsoncrush, shellout) and by the contextopt middleware that orchestrates them.
Package contentcomp defines the shared, dependency-free contracts used by the deterministic per-message content compressors (jsoncrush, shellout) and by the contextopt middleware that orchestrates them.
contentcomp/jsoncrush
Package jsoncrush provides a deterministic, lossless "crush" of JSON arrays of objects: keys common to every row (with an identical value) are hoisted into a shared "_defaults" block, leaving only per-row deviations.
Package jsoncrush provides a deterministic, lossless "crush" of JSON arrays of objects: keys common to every row (with an identical value) are hoisted into a shared "_defaults" block, leaving only per-row deviations.
contentcomp/shellout
Package shellout provides deterministic, opt-in compressors for noisy CLI / log / diff output (ported in spirit from headroom's log/diff/search compressors and lean-ctx's pattern table).
Package shellout provides deterministic, opt-in compressors for noisy CLI / log / diff output (ported in spirit from headroom's log/diff/search compressors and lean-ctx's pattern table).
costtrack
Package costtrack provides a facade for real-time LLM cost tracking: it wires the activity bus, models.dev catalog pricer, Prometheus metrics collector, cost-saver analysis, and per-session real-time aggregation into a single builder API.
Package costtrack provides a facade for real-time LLM cost tracking: it wires the activity bus, models.dev catalog pricer, Prometheus metrics collector, cost-saver analysis, and per-session real-time aggregation into a single builder API.
costtrack/otel
Package otel implements costtrack.Recorder against the OpenTelemetry global metric scope (libs/otelmetrics).
Package otel implements costtrack.Recorder against the OpenTelemetry global metric scope (libs/otelmetrics).
docid
Package docid provides shared helpers to compute deterministic document base IDs and content hashes, usable both inside indexing graphs (as a lambda) and outside of them (e.g.
Package docid provides shared helpers to compute deterministic document base IDs and content hashes, usable both inside indexing graphs (as a lambda) and outside of them (e.g.
modelsdev
Package modelsdev provides a provider-generic models.dev catalog: per-model context/output limits and USD-per-million-token cost, mirroring kilocode's core/models-dev.
Package modelsdev provides a provider-generic models.dev catalog: per-model context/output limits and USD-per-million-token cost, mirroring kilocode's core/models-dev.
modelsdev/gen command
Command gen refreshes the committed libs/modelsdev/api.json snapshot from models.dev.
Command gen refreshes the committed libs/modelsdev/api.json snapshot from models.dev.
otelmetrics
Package otelmetrics is a thin, reusable wrapper over the OpenTelemetry global MeterProvider.
Package otelmetrics is a thin, reusable wrapper over the OpenTelemetry global MeterProvider.
promptenhance
Package promptenhance provides prompt rewriting using a small/cheap model.
Package promptenhance provides prompt rewriting using a small/cheap model.
toolkit/checkup
Package checkup provides types and helpers for component connectivity and RBAC diagnostics.
Package checkup provides types and helpers for component connectivity and RBAC diagnostics.
toolkit/confirm
Package confirm provides shared helpers for gating destructive tool operations behind an explicit confirmation flag.
Package confirm provides shared helpers for gating destructive tool operations behind an explicit confirmation flag.
toolkit/dagger
Package dagger provides a wrapper around the Dagger engine client for building and managing OCI containers with shared cache volumes and egress proxy bindings.
Package dagger provides a wrapper around the Dagger engine client for building and managing OCI containers with shared cache volumes and egress proxy bindings.
toolkit/egress
Package egress provides a policy-driven HTTP/HTTPS egress proxy that enforces "local network forbidden by default" with an allowlist and AllowLocalNetwork toggle.
Package egress provides a policy-driven HTTP/HTTPS egress proxy that enforces "local network forbidden by default" with an allowlist and AllowLocalNetwork toggle.
toolkit/osclient
Package osclient provides a shared constructor for the eino-ext OpenSearch v4 client (github.com/disaster37/opensearch/v4).
Package osclient provides a shared constructor for the eino-ext OpenSearch v4 client (github.com/disaster37/opensearch/v4).
toolkit/profile
Package profile provides project-type detection and base-image selection.
Package profile provides project-type detection and base-image selection.
toolkit/safety
Package safety provides shared primitives for building a safety control layer around LLM tool invocations.
Package safety provides shared primitives for building a safety control layer around LLM tool invocations.
toolkit/strutil
Package strutil provides small string helpers shared across components: length-capped truncation with a marker, and extraction of a JSON block from free-form LLM output.
Package strutil provides small string helpers shared across components: length-capped truncation with a marker, and extraction of a JSON block from free-form LLM output.
toolkit/toolutil
Package toolutil provides small shared helpers for tool components: consistent "not found" errors for named instances/clusters and sorted map key extraction for configuration maps.
Package toolutil provides small shared helpers for tool components: consistent "not found" errors for named instances/clusters and sorted map key extraction for configuration maps.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL