Documentation
¶
Overview ¶
Package fiber is an agent library you compose in Go. New assembles the agent registry, the bus, the router, the durable runtime, the sandbox, knowledge, thread journals, files, MCP tool providers, the author agent and the connectors into an App, and Run drives it in process. It is a library: there is no service, no configuration file and no environment variable, every choice is a value passed to an Option, and anything not passed is the in-memory implementation, which is complete rather than a stub. The one command in the module, cmd/fiber, is a program built on it like any other, for running a spec locally (fiber run).
pool, _ := pgxpool.New(ctx, dsn) // the program's own pool
pg := bus.NewPostgres(pool)
_ = pg.Migrate(ctx)
app, err := fiber.New(ctx,
fiber.WithTenant("acme"),
fiber.WithPostgres(pool), // every store family on this pool
fiber.WithBus(pg), // and the bus
fiber.WithModelProvider("house", newHouseProvider),
)
if err != nil { ... }
defer app.Close()
go app.Run(ctx)
acc, err := app.Invoke(ctx, tag)
Code-shaped extensions are options too: a model provider, a tool source, a connector, an MCP tool provider. Configuration from files or the environment belongs to the program embedding fiber (warp is one), which turns it into these options.
Where it sits ¶
The package is the module root because it composes everything under pkg/, and nothing under pkg/ may depend on it. An App listens on nothing: connectors that receive webhooks are offered as http.Handlers for the embedding program to mount.
Index ¶
- Constants
- Variables
- func ControlStreams(compactOnRequest bool) int
- type App
- func (a *App) Answer(ctx context.Context, req runtime.AnswerRequest) (answer payload.Answer, first bool, err error)
- func (a *App) Blobs() blob.Store
- func (a *App) Bus() bus.Bus
- func (a *App) Close() error
- func (a *App) Compact(ctx context.Context, req runtime.CompactRequest) error
- func (a *App) Connectors() *connector.Registry
- func (a *App) Index(ctx context.Context, tenant, source string, paths ...string) (IndexResult, error)
- func (a *App) Invoke(ctx context.Context, tag envelope.Tag) (runtime.Acceptance, error)
- func (a *App) Knowledge() knowledge.Store
- func (a *App) Providers() []string
- func (a *App) Registry() registry.Store
- func (a *App) Router() *router.Router
- func (a *App) Run(ctx context.Context) error
- func (a *App) RunDelivery(ctx context.Context) error
- func (a *App) RunExecution(ctx context.Context) error
- func (a *App) Runtime() *runtime.Runtime
- func (a *App) Status(ctx context.Context, tenant, runID string) (Run, error)
- func (a *App) Stop(ctx context.Context, req runtime.StopRequest) error
- func (a *App) Threads() thread.Store
- func (a *App) ToolProviders() toolprovider.Store
- func (a *App) ToolsFor(ctx context.Context, tag envelope.Tag) (agentrt.Granted, error)
- func (a *App) WebhookHandler() http.Handler
- func (a *App) Webhooks() map[string]http.Handler
- type GitHub
- type IndexResult
- type Jira
- type Ledger
- type Option
- func WithAuthor(provider, model string) Option
- func WithBlobs(s blob.Store) Option
- func WithBus(b bus.Bus) Option
- func WithCompaction(c agentrt.Compaction) Option
- func WithConcurrency(n int) Option
- func WithConnector(c connector.Connector) Option
- func WithDurable(l Ledger, q dqueue.Queue) Option
- func WithEmbedder(e knowledge.Embedder) Option
- func WithExecutor(x runtime.Executor) Option
- func WithGitHub(c GitHub) Option
- func WithJira(c Jira) Option
- func WithKnowledge(s knowledge.Store) Option
- func WithLogger(log *slog.Logger) Option
- func WithMetrics(rec metrics.Recorder) Option
- func WithModelProvider(name string, fn agentrt.ProviderFunc) Option
- func WithOpenAICompatible(ep agentrt.OpenAICompatible) Option
- func WithPersonCredentials(r mcptools.PersonResolver) Option
- func WithPostgres(pool *pgxpool.Pool) Option
- func WithRegistry(s registry.Store) Option
- func WithRuntimeOptions(opts ...runtime.Option) Option
- func WithSchedules(s ...cron.Schedule) Option
- func WithSlack(c Slack) Option
- func WithTenant(tenant string) Option
- func WithThreads(s thread.Store) Option
- func WithToolProvider(p toolprovider.Provider, accept ...toolprovider.Tool) Option
- func WithToolProviders(s toolprovider.Store) Option
- func WithToolSource(c runtime.Catalog) Option
- func WithTools(tools ...saigetypes.Tool) Option
- func WithWebhooks(endpoints map[string]webhook.Endpoint) Option
- func WithWorkerOptions(opts ...worker.Option) Option
- func WithWorkspace(dir string) Option
- type Run
- type Slack
- type Status
Constants ¶
const HeaderJiraSecret = "X-Fiber-Secret"
HeaderJiraSecret carries the shared secret a Jira webhook is registered with. Jira signs nothing, so the secret is whatever the person who configured the URL put in a header; see jiraSecret.
Variables ¶
var ErrConfig = errors.New("fiber: invalid configuration")
ErrConfig reports a composition that cannot be what its author meant: a half-configured connector, a trigger connector with no tenant to raise tags in, a tool provider declared twice, a tool pinned with no schema hash. New fails with it before anything runs.
var ErrNotFound = errors.New("fiber: not found")
ErrNotFound reports a run that does not exist or belongs to another tenant. The two are one error on purpose: telling them apart would confirm existence across a tenant boundary.
ErrUnavailable reports a backend New could not migrate. Retrying unchanged is the right response.
Functions ¶
func ControlStreams ¶
ControlStreams is how many control subscriptions a running turn holds for its whole turn: one for stop requests, and one more for requests to compact when compactOnRequest. On Redis each is a pooled connection, so a program sizing a Redis client for an App wants bus.RedisPoolSize(concurrency, ControlStreams(compactOnRequest)).
Types ¶
type App ¶
type App struct {
// contains filtered or unexported fields
}
App is fiber assembled: every long-lived component a process owns, in the order data flows through them.
registry → runtime → bus → router → connector sinks
↑ ↓
anchor worker a surface somewhere
Nothing here is a stub standing in for a deployment. The in-memory registry, bus, ledger and queue are complete implementations of the same interfaces the shared backends implement; which one runs is an Option that passes a constructed value, never a change to anything below it.
An App listens on nothing. Connectors that receive webhooks are exposed as http.Handlers (Webhooks, WebhookHandler) for the embedding program to mount.
func New ¶
New assembles the system from opts and returns before anything runs: call Run to start delivery and execution, and Close to release what New made. Every backend not passed by an option is the in-memory implementation; WithPostgres puts every store family on one pool, migrated here. New opens no connection of its own and reads no environment or file.
It is deliberately linear: read it top to bottom and you have read how fiber fits together.
func (*App) Answer ¶
func (a *App) Answer(ctx context.Context, req runtime.AnswerRequest) (answer payload.Answer, first bool, err error)
Answer answers a question a run is parked on, and returns the answer the question has, which is this one only when first is true. See runtime.Runtime.Answer for the errors.
func (*App) Close ¶
Close releases what New made: MCP sessions and a workspace New created. Every backend passed by an option, the Postgres pool included, is the caller's and is left alone. It is idempotent. Stop Run first.
func (*App) Compact ¶
Compact asks a run's running turn to compact its history. It needs Config.Compaction.OnRequest; see runtime.Runtime.Compact.
func (*App) Connectors ¶
Connectors is the connector registry.
func (*App) Index ¶
func (a *App) Index(ctx context.Context, tenant, source string, paths ...string) (IndexResult, error)
Index writes text files into the knowledge store under source, for tenant. An agent whose spec lists source under "sources" is then grounded in them, and its answers carry citations. A directory is walked for Markdown and plain text (hidden directories skipped); a file named explicitly is indexed whatever its extension. Each document's URI is its path as given.
func (*App) Invoke ¶
Invoke accepts a tag: it registers the tag's routes with the router and then accepts the run durably. It returns before any inference.
The order matters: routes are registered before the run is accepted, because accept publishes the run's first event and an event for a run the router has no routes for has nowhere to go. RunID is a pure function of the tenant and tag id, so the routes can be registered before the run exists.
The tag's Tenant and Actor are trusted as given. An embedding program that accepts tags from callers must set both from the caller's credential, never from a request body.
func (*App) Providers ¶
Providers is the model provider names specs may select: the built-ins and every extension's.
func (*App) Run ¶
Run starts delivery and execution and blocks until ctx is done or one of them fails, then stops both. A cancelled ctx is not a failure.
func (*App) RunDelivery ¶
RunDelivery runs only the router: it reads the bus and renders events onto connector sinks, accepting and executing nothing, so delivery can scale apart from execution. It needs a shared bus to be useful.
func (*App) RunExecution ¶
RunExecution runs only the durable worker and the triggers: it executes runs and accepts what connectors raise, and delivers nothing.
func (*App) Status ¶
Status reads a run's durable record, scoped to tenant. A run of another tenant is ErrNotFound, exactly like one that does not exist.
The record trails the run's terminal event briefly. A run publishes lifecycle.completed, failed or stopped from inside its turn, and the worker records how it ended only once the turn has returned, so a Status read the moment that event arrives can still report accepted. The ledger is the authority: a worker that dies in between leaves the run pending, and the next attempt replays it. A caller that needs the two to agree polls until the status is Terminal.
func (*App) Stop ¶
Stop asks a run to stop. See runtime.Runtime.Stop for what a nil error does and does not mean; errors are the runtime's (runtime.ErrInvalid, runtime.ErrStopUnavailable).
func (*App) ToolProviders ¶
func (a *App) ToolProviders() toolprovider.Store
ToolProviders is the MCP tool provider store.
func (*App) ToolsFor ¶ added in v0.22.0
ToolsFor reports what a run of tag would be granted, without accepting it: the tools the current revision of tag's agent in tag's tenant would show its model, and the grants it would drop, each with its reason. The tools are resolved as a turn of that run would resolve them, for its tenant, its surface and its actor, so a person-scoped MCP grant expands for tag's actor, and an MCP server may be reached to expand a group. No tool is called and no model client is built, so it needs no model credential. The tag is trusted as given, as Invoke trusts it, and needs only Tenant and Agent.
It asks the App's sandbox. An executor passed by WithExecutor is asked too if it has a method ToolsFor(context.Context, runtime.Request) (agentrt.Granted, error); otherwise the error is errors.ErrUnsupported.
func (*App) WebhookHandler ¶
WebhookHandler serves every webhook connector under /connectors/{name}, for a program that wants one mount point.
func (*App) Webhooks ¶
Webhooks returns the connectors that receive their own webhooks, by connector name. Each verifies its own signature, so no unverified body reaches anything else. Mount them wherever the embedding program serves HTTP; the path a third party POSTs to is that connector's contract.
type GitHub ¶
type GitHub struct {
Token, WebhookSecret string
Owners []string
ReadRepositories []string
Bots map[string]string
Checks bool
// Login is the app's own login. A comment that mentions it and names no
// agent is answered by DefaultAgent, and with none it raises nothing.
Login, DefaultAgent string
}
GitHub configures the built-in GitHub connector (WithGitHub). Token and WebhookSecret together turn it on, and it needs WithTenant.
type IndexResult ¶
type IndexResult struct {
// Files is how many files were read; Skipped how many were not text.
Files, Skipped int
// Changed is how many documents were new or different, and Chunks how
// many chunks they were written as. Re-indexing unchanged files
// changes nothing.
Changed, Chunks int
}
IndexResult is what Index did.
type Jira ¶
type Jira struct {
Sites map[string]string
Email, Token, WebhookSecret string
Bots map[string]string
}
Jira configures the built-in Jira connector (WithJira). Sites (short key to base URL; the key is what a jira:// address names) turns it on, and then Email, Token, WebhookSecret and WithTenant are required.
type Ledger ¶
Ledger is the run ledger an App executes from: anchor's ledger plus the point read Status polls with. ledger.NewMemory and durable.Open's ledger both satisfy it.
type Option ¶
type Option func(*options)
Option is one choice New is given.
func WithAuthor ¶
WithAuthor chooses what the built-in author agent runs on. Without it the agent is seeded on the offline provider.
func WithBus ¶
WithBus sets the broker: bus.NewMemory (the default), bus.NewRedis or bus.NewPostgres, or any implementation that passes bustest.
func WithCompaction ¶
func WithCompaction(c agentrt.Compaction) Option
WithCompaction sets the history compaction every agent runs with. The zero value never compacts; OnRequest lets a host ask a running turn to compact (App.Compact).
func WithConcurrency ¶
WithConcurrency sets how many runs the worker executes at once (default one).
func WithConnector ¶
WithConnector registers a connector beside the built-in ones. Its roles (trigger, sink, actor) are derived from the interfaces it implements, as every connector's are.
func WithDurable ¶
WithDurable sets the run ledger and queue runs execute from, for example the two durable.Open returns. Both are required.
func WithEmbedder ¶
WithEmbedder sets the embedder of the knowledge store New builds (memory, or Postgres with WithPostgres). Without it the offline hashing embedder is used. A store passed by WithKnowledge brings its own.
func WithExecutor ¶
WithExecutor replaces the playscape sandbox a turn runs in. Model providers, tool sources, compaction and knowledge are wired into the sandbox, so an executor passed here brings its own.
func WithKnowledge ¶
WithKnowledge sets the knowledge store agents are grounded in.
func WithLogger ¶
WithLogger sends operational output to log. Without it it is discarded.
func WithMetrics ¶
WithMetrics records counters to rec. Without it nothing is recorded.
func WithModelProvider ¶
func WithModelProvider(name string, fn agentrt.ProviderFunc) Option
WithModelProvider makes a model provider selectable by name: a spec whose provider is name runs on what fn builds. The registry New builds accepts specs naming it, and a built-in of the same name is replaced.
func WithOpenAICompatible ¶
func WithOpenAICompatible(ep agentrt.OpenAICompatible) Option
WithOpenAICompatible registers an OpenAI-compatible endpoint under ep.Name. It is WithModelProvider with ep.Provider(); the key is read from the environment variable ep.KeyEnv names when an agent is built.
func WithPersonCredentials ¶ added in v0.22.0
func WithPersonCredentials(r mcptools.PersonResolver) Option
WithPersonCredentials sets how a person-scoped MCP tool provider (toolprovider.ScopePerson) finds the credential of the person a run acts for. That person is the actor on the run's tag as it was accepted, which the program composing fiber sets from the caller's credential (a surface marked ActAs names the person it authenticated) and which no model output can change. A reference the resolver returns is resolved like a provider's own ("env:NAME"); a resolver that holds the secrets returns them. A person it has nothing for gets no tools from such a provider, the model is told they have not connected a credential, and the shared credential is never used instead. Without this option every person-scoped grant is unavailable.
func WithPostgres ¶
WithPostgres puts every store family on pool: the agent registry, the run ledger and queue, knowledge, thread journals and MCP tool providers. New migrates each. A store passed by its own option wins over this one. The bus is chosen separately (WithBus with bus.NewPostgres or bus.NewRedis).
func WithRegistry ¶
WithRegistry sets the agent store. The store decides which providers it accepts (registry.WithProviders); App.Providers lists the names this App can run.
func WithRuntimeOptions ¶
WithRuntimeOptions adds options to the durable runtime, after the App's own, so they can override them.
func WithSchedules ¶
WithSchedules registers the cron connector with its standing requests.
func WithTenant ¶
WithTenant sets the authorization scope this deployment serves. It is stamped onto every tag a connector raises (a trigger has no credential to derive one from), mentions on Slack, GitHub and Jira resolve agents in it, the author agent is seeded for it, and tool providers declared without a tenant are recorded under it. There is no default: without it nothing is seeded, and WithSlack, WithGitHub and WithJira are ErrConfig, since they would raise nothing a run could be accepted for. A schedule carries its own tenant.
func WithThreads ¶
WithThreads sets the conversation journal.
func WithToolProvider ¶
func WithToolProvider(p toolprovider.Provider, accept ...toolprovider.Tool) Option
WithToolProvider records an MCP tool provider at startup and accepts the tools in accept from it, each pinned by Name and SchemaHash and accepted with its Class (write when empty). Only an offered tool whose schema hash matches its pin is accepted, and its description may not change once it has been; anything the server adds or changes stays pending and is logged with its hash. A tool with no SchemaHash, or a provider declared twice, is ErrConfig. An empty p.Tenant is the deployment's tenant. Agents reach the provider with an "mcp:<name>" or "mcp:<name>:write" grant.
A person-scoped provider is not dialled at startup, since it has no credential of its own: each tool in accept must then carry the Description and InputSchema the server offers, and is accepted in that form when its SchemaHash matches the schema. Its runs reach it with each person's own credential (WithPersonCredentials).
func WithToolProviders ¶
func WithToolProviders(s toolprovider.Store) Option
WithToolProviders sets the MCP tool provider store.
func WithToolSource ¶
WithToolSource adds a catalog that spec tool names resolve against, after the connectors' actions. It is built per turn, so it can bind tools to the run's tenant and surface; action reports a call as an action.taken event.
func WithTools ¶
func WithTools(tools ...saigetypes.Tool) Option
WithTools adds a fixed set of tools, resolved by name for every turn. It is WithToolSource for tools that need nothing from the run.
func WithWebhooks ¶
WithWebhooks registers the outbound webhook sink with its endpoints, by the workspace a webhook:// address names. Each needs a secret.
func WithWorkerOptions ¶
WithWorkerOptions adds options to the durable worker Run starts, after the App's own.
func WithWorkspace ¶
WithWorkspace sets the directory the sandbox writes agent artifacts under. Without it New makes a temporary directory and Close removes it.
type Run ¶
type Run struct {
ID string
Tenant string
Agent string
Rev int
Origin string
Topic topic.Topic
Status Status
Tag envelope.Tag
LastSeq uint64
Error string
// StopReason and StoppedBy say why a stopped run was stopped and who
// asked. Empty unless Status is StatusStopped.
StopReason string
StoppedBy string
// Usage is what the run spent, nil while nothing is recorded.
Usage *payload.RunUsage
// Question is what the run is waiting on a person for, set while
// Status is StatusParked.
Question *payload.Question
CreatedAt time.Time
EndedAt time.Time
}
Run is the durable record of one invocation. It is a projection of the ledger, so reading one never touches a worker and polling it is cheap.
type Slack ¶
type Slack struct {
Token, SigningSecret string
// Team is the workspace id deliveries are confined to.
Team string
// AppID marks messages this deployment posted when a thread is
// reconciled.
AppID string
// DefaultAgent answers a mention of the app that names no agent.
DefaultAgent string
// Bots maps a Slack user id to the agent it stands for.
Bots map[string]string
}
Slack configures the built-in Slack connector (WithSlack). Token and SigningSecret together turn it on; one without the other is ErrConfig, and so is either without WithTenant.
type Status ¶
type Status string
Status is where a run is in its lifecycle. It mirrors the lifecycle.* event kinds: status answers "where is it now", the events answer "how did it get there".
const ( StatusAccepted Status = "accepted" StatusParked Status = "parked" StatusCompleted Status = "completed" StatusFailed Status = "failed" // StatusStopped is a run that ended because it was asked to. It is // terminal, and it is neither completed nor failed. StatusStopped Status = "stopped" )
Run statuses.
Source Files
¶
Directories
¶
| Path | Synopsis |
|---|---|
|
cmd
|
|
|
fiber
command
Command fiber validates an agent spec locally: it runs the spec once, in this process, and prints what the run does.
|
Command fiber validates an agent spec locally: it runs the spec once, in this process, and prints what the run does. |
|
examples
|
|
|
downstream
command
Command downstream is what a team building on fiber ships instead of a fork: its own program, composing fiber in Go, plus what it registers.
|
Command downstream is what a team building on fiber ships instead of a fork: its own program, composing fiber in Go, plus what it registers. |
|
local
command
Command local is fiber, end to end, in one process.
|
Command local is fiber, end to end, in one process. |
|
pkg
|
|
|
address
Package address is the naming layer of the mesh: a stable URI for any place a tag can come from or be delivered to.
|
Package address is the naming layer of the mesh: a stable URI for any place a tag can come from or be delivered to. |
|
agentrt
Package agentrt builds a running agent from a pinned agent revision.
|
Package agentrt builds a running agent from a pinned agent revision. |
|
agentrt/payload
Package payload is the body of every event an agent run publishes.
|
Package payload is the body of every event an agent run publishes. |
|
agentspec
Package agentspec is the canonical definition of an agent, and the rules that decide when two definitions are the same one.
|
Package agentspec is the canonical definition of an agent, and the rules that decide when two definitions are the same one. |
|
attachment
Package attachment is the typed reference to a file an agent was handed.
|
Package attachment is the typed reference to a file an agent was handed. |
|
attachment/intake
Package intake is how a file's bytes get into the blob store and come out as an attachment.Attachment.
|
Package intake is how a file's bytes get into the blob store and come out as an attachment.Attachment. |
|
attachment/resolve
Package resolve turns attachment references into model input.
|
Package resolve turns attachment references into model input. |
|
attachment/resolve/resolvetest
Package resolvetest provides deterministic stand-ins for the backends pkg/attachment/resolve only defines interfaces for: a Transcriber, a FrameSampler and a Prober.
|
Package resolvetest provides deterministic stand-ins for the backends pkg/attachment/resolve only defines interfaces for: a Transcriber, a FrameSampler and a Prober. |
|
blob
Package blob is a content-addressed store for the bytes of files an agent is handed: a screenshot pasted into a Slack thread, a log attached to a GitHub issue, a PDF on a Jira ticket.
|
Package blob is a content-addressed store for the bytes of files an agent is handed: a screenshot pasted into a Slack thread, a log attached to a GitHub issue, a PDF on a Jira ticket. |
|
blob/blobtest
Package blobtest is the conformance suite every blob store must pass.
|
Package blobtest is the conformance suite every blob store must pass. |
|
bus
Package bus is the broker: a run publishes its events once, and every consumer that asked for them receives them.
|
Package bus is the broker: a run publishes its events once, and every consumer that asked for them receives them. |
|
bus/bustest
Package bustest is the conformance suite every bus backend must pass.
|
Package bustest is the conformance suite every bus backend must pass. |
|
connector
Package connector defines what it means to participate in the mesh.
|
Package connector defines what it means to participate in the mesh. |
|
connectors
Package connectors holds the mesh: the concrete peers that raise tags and render events onto real surfaces.
|
Package connectors holds the mesh: the concrete peers that raise tags and render events onto real surfaces. |
|
connectors/author
Package author turns the agent control plane into tools an agent can call.
|
Package author turns the agent control plane into tools an agent can call. |
|
connectors/cron
Package cron is the schedule peer in the mesh: a trigger, and only a trigger.
|
Package cron is the schedule peer in the mesh: a trigger, and only a trigger. |
|
connectors/github
Package github is the GitHub peer in the mesh: trigger, sink and actor.
|
Package github is the GitHub peer in the mesh: trigger, sink and actor. |
|
connectors/internal/files
Package files is the part of file intake every trigger shares: collecting a message's files onto its tag under the per-tag caps, logging what was left out, and handing the tag off without discarding work the provider stopped waiting for.
|
Package files is the part of file intake every trigger shares: collecting a message's files onto its tag under the per-tag caps, logging what was left out, and handing the tag off without discarding work the provider stopped waiting for. |
|
connectors/internal/httpjson
Package httpjson is the JSON-over-HTTP client the connectors' real API implementations share.
|
Package httpjson is the JSON-over-HTTP client the connectors' real API implementations share. |
|
connectors/internal/inbound
Package inbound is the front door every webhook trigger shares: authenticate the request, then hand the raw bytes to whoever knows how to read them.
|
Package inbound is the front door every webhook trigger shares: authenticate the request, then hand the raw bytes to whoever knows how to read them. |
|
connectors/internal/render
Package render accumulates one run's event stream into a document a sink can draw, repeatedly, without ever drawing something stale.
|
Package render accumulates one run's event stream into a document a sink can draw, repeatedly, without ever drawing something stale. |
|
connectors/internal/sink
Package sink is the delivery engine every human-facing connector shares: one message per run, edited as the run proceeds.
|
Package sink is the delivery engine every human-facing connector shares: one message per run, edited as the run proceeds. |
|
connectors/jira
Package jira is the Jira peer in the mesh: trigger, sink and actor.
|
Package jira is the Jira peer in the mesh: trigger, sink and actor. |
|
connectors/mention
Package mention finds the agent a human tagged and removes the mention from the text the agent will read.
|
Package mention finds the agent a human tagged and removes the mention from the text the agent will read. |
|
connectors/slack
Package slack is the Slack peer in the mesh: trigger, sink and actor.
|
Package slack is the Slack peer in the mesh: trigger, sink and actor. |
|
connectors/webhook
Package webhook is the outbound peer in the mesh: a sink, and only a sink.
|
Package webhook is the outbound peer in the mesh: a sink, and only a sink. |
|
durable
Package durable owns the Postgres schema that anchor's run ledger and queue are stored in, so a run in flight outlives the process that accepted it.
|
Package durable owns the Postgres schema that anchor's run ledger and queue are stored in, so a run in flight outlives the process that accepted it. |
|
envelope
Package envelope is the contract every fiber client speaks, independent of transport.
|
Package envelope is the contract every fiber client speaks, independent of transport. |
|
internal/pgrename
Package pgrename moves a database created before fiber's rename forward: a store's tables that still carry the old prefix in the current schema, with their indexes and constraints, are renamed to the fiber_ prefix.
|
Package pgrename moves a database created before fiber's rename forward: a store's tables that still carry the old prefix in the current schema, with their indexes and constraints, are renamed to the fiber_ prefix. |
|
knowledge
Package knowledge is the retrieval layer: it indexes documents and answers a query with the passages most likely to contain the answer, each one carrying enough provenance to be cited.
|
Package knowledge is the retrieval layer: it indexes documents and answers a query with the passages most likely to contain the answer, each one carrying enough provenance to be cited. |
|
knowledge/knowledgetest
Package knowledgetest is the conformance suite every knowledge.Store must pass: exact citations, idempotent and atomic reindexing, tenant and source confinement, deletion, hybrid fusion, reranking, limits, stable order, and refusing input or vectors the store cannot keep.
|
Package knowledgetest is the conformance suite every knowledge.Store must pass: exact citations, idempotent and atomic reindexing, tenant and source confinement, deletion, hybrid fusion, reranking, limits, stable order, and refusing input or vectors the store cannot keep. |
|
mcptools
Package mcptools connects to the MCP servers pkg/toolprovider records and turns the tools an admin accepted into callables an agent can use.
|
Package mcptools connects to the MCP servers pkg/toolprovider records and turns the tools an admin accepted into callables an agent can use. |
|
registry
Package registry is the agent control plane: the append-only record of what every agent has ever been, scoped by tenant.
|
Package registry is the agent control plane: the append-only record of what every agent has ever been, scoped by tenant. |
|
registry/registrytest
Package registrytest is the conformance suite every registry.Store must pass.
|
Package registrytest is the conformance suite every registry.Store must pass. |
|
router
Package router is the delivery half of the mesh: it turns "the agent said something" into "the surface shows it".
|
Package router is the delivery half of the mesh: it turns "the agent said something" into "the surface shows it". |
|
runtime
Package runtime is the durable turn: where a tag becomes a run.
|
Package runtime is the durable turn: where a tag becomes a run. |
|
signature
Package signature authenticates inbound webhook requests.
|
Package signature authenticates inbound webhook requests. |
|
thread
Package thread is the memory of a conversation: an append-only journal of what was said in one thread, kept so that the next run in that thread can be shown it.
|
Package thread is the memory of a conversation: an append-only journal of what was said in one thread, kept so that the next run in that thread can be shown it. |
|
thread/threadtest
Package threadtest holds two things for tests of the thread journal: Run, the conformance suite every thread.Store must pass, and Surface, a thread.Lister that holds messages in memory and lets a test do to them what people do on a real surface, which is post, edit and delete.
|
Package threadtest holds two things for tests of the thread journal: Run, the conformance suite every thread.Store must pass, and Surface, a thread.Lister that holds messages in memory and lets a test do to them what people do on a real surface, which is post, edit and delete. |
|
toolprovider
Package toolprovider is the control plane for external tool servers: the record of which MCP servers a tenant may reach, and the versioned list of tools an admin has accepted from each.
|
Package toolprovider is the control plane for external tool servers: the record of which MCP servers a tenant may reach, and the versioned list of tools an admin has accepted from each. |
|
toolprovider/toolprovidertest
Package toolprovidertest is the conformance suite every toolprovider.Store must pass: versioned provider records with stale edits refused, tenant isolation, validation, a credential scope that reads back as written (and a person-scoped provider that can name no shared credential), nothing accepted until an admin accepts it, and numbered, immutable, pinnable snapshots whose schema hashes the store recomputes.
|
Package toolprovidertest is the conformance suite every toolprovider.Store must pass: versioned provider records with stale edits refused, tenant isolation, validation, a credential scope that reads back as written (and a person-scoped provider that can name no shared credential), nothing accepted until an admin accepts it, and numbered, immutable, pinnable snapshots whose schema hashes the store recomputes. |
|
topic
Package topic is the addressing scheme of the fiber bus.
|
Package topic is the addressing scheme of the fiber bus. |