ai library
Public entrypoint for Flint's AI runtime, providers, tools, workflows, memory, and persistence APIs.
Classes
- AiAgent
- Contract implemented by runnable agents.
- AiArtifactStore
- Store for persisted AI artifacts.
- AiEvent
- Timestamped event emitted during a run.
- AiExecutor
- Contract for executing an AI plan.
- AiGoal
- High-level task submitted to an agent.
- AiHttpClient
- Contract for HTTP clients used by AI providers.
- AiHttpRequest
- Immutable outbound AI HTTP request.
- AiHttpResponse
- Immutable AI HTTP response wrapper.
- AiMemoryStore
- Contract for AI run-event and thread-message memory storage.
- AiPlan
- Ordered collection of steps produced by a planner.
- AiPlanner
- Contract for turning an agent run into a plan.
- AiPlanStep
- A single executable step in an AI plan.
- AiProviderRegistry
- Registry for chat, image, and embedding providers.
- AiRepository
- Bundle of stores used by the AI runtime for persistence.
- AiRetryPolicy
- Retry configuration for provider HTTP requests.
- AiRun
- Mutable state container for an individual agent execution.
- AiRunContext
- Shared execution context available to planners, executors, and agents.
- AiRunResult
- Final output of an agent run.
- AiRunStore
- Store for persisted AI run snapshots.
- AiThreadStore
- Store for persisted AI thread snapshots.
- AiTool
- Contract implemented by executable AI tools.
- AiToolContext
- Context passed into tool execution.
- AiToolInvocation
- Authorization request describing a planned tool call.
- AiToolPolicy
- Contract for authorizing tool execution.
- AiToolRegistry
- Registry for executable AI tools.
- AiTraceStore
- Store for persisted AI trace events.
- AiWorkflow
- Contract for named reusable AI workflows.
- AiWorkflowContext
- Execution context passed into a workflow.
- AiWorkflowRegistry
- Registry for named workflows.
- AiWorkflowRunResult
- Result wrapper returned by FlintAi.runWorkflow.
- AllowAllAiToolPolicy
- Permissive tool policy intended only for explicit opt-in use.
- AnthropicChatProvider
- Chat provider adapter for Anthropic's Messages API.
- AutoAiMemoryStore
- Default memory store used by the standalone package.
- AutoAiRepository
- Default repository used by the standalone package.
- BasicTaskAgent
- Minimal example agent that copies the incoming goal into run state.
- ChatEvent
- Streaming event emitted by a chat provider.
- ChatMessage
- Single chat message in a provider request.
- ChatProvider
- Contract for chat-capable AI providers.
- ChatRequest
- Input payload for a chat completion request.
- ChatResult
- Non-streaming chat completion result.
- ChatUsage
- Token usage metadata returned by a provider.
- DartIoAiHttpClient
-
Default
dart:iobased HTTP client for provider adapters. - DefaultAiExecutor
- Default executor that runs plan steps sequentially.
- DefaultAiPlanner
- Default planner that delegates planning to the agent itself.
- DenyAllAiToolPolicy
- Tool policy that rejects every tool invocation.
- EmbeddingProvider
- Contract for embedding-capable AI providers.
- EmbeddingRequest
- Input payload for an embedding request.
- EmbeddingResult
- Result payload for an embedding request.
- FlintAi
- Main entry point for Flint's AI runtime.
- FlintAutoAiMemoryStore
- AI memory store that uses Flint DB when available and falls back to memory.
- FlintAutoAiRepository
- AI repository that uses Flint DB when available and falls back to memory.
- FlintDbAiArtifactStore
- Database-backed AI artifact store for Flint Dart applications.
- FlintDbAiMemoryStore
- Database-backed AI memory store for Flint Dart applications.
- FlintDbAiRunStore
- Database-backed AI run store for Flint Dart applications.
- FlintDbAiThreadStore
- Database-backed AI thread store for Flint Dart applications.
- FlintDbAiTraceStore
- Database-backed AI trace store for Flint Dart applications.
- GeminiChatProvider
- Chat provider adapter for Google Gemini.
- ImageGenerationRequest
- Input payload for an image generation request.
- ImageGenerationResult
- Result payload for an image generation request.
- ImageProvider
- Contract for image-capable AI providers.
- InMemoryAiArtifactStore
- In-memory artifact store for development and tests.
- InMemoryAiMemoryStore
- In-memory implementation of AiMemoryStore for development and tests.
- InMemoryAiRunStore
- In-memory run store for development and tests.
- InMemoryAiThreadStore
- In-memory thread store for development and tests.
- InMemoryAiTraceStore
- In-memory trace store for development and tests.
- OpenAiChatProvider
- Chat provider adapter for OpenAI-compatible chat completions.
- ProductionAiToolPolicy
- Production-oriented tool policy for deployed applications.
- RetryingAiHttpClient
- HTTP client wrapper that retries transient provider failures.
- SafeDefaultAiToolPolicy
- Safe default policy for development and low-risk tools.
Enums
- AiRunStatus
- Lifecycle states for an AI run.
Extensions
- FlintAiEnvSetup on FlintAi
- Environment-backed setup helpers for Flint AI.
Properties
-
flintAiTables
→ List<
Table> -
Canonical table definitions used by Flint AI database adapters.
final
Functions
-
aiSseDataEvents(
Stream< String> chunks) → Stream<String> -
Parses Server-Sent Events and yields each
data:payload. -
generateAiRunId(
) → String - Generates a random run id for AI executions.
Exceptions / Errors
- AiHttpException
- Normalized HTTP transport error used by AI providers.
- AiProviderException
- Normalized provider exception used across AI adapters.