flutter_local_agent_kit 1.0.0
flutter_local_agent_kit: ^1.0.0 copied to clipboard
A production-ready, offline-first AI framework for Flutter. Orchestrates resident LLM inference, local RAG knowledge retrieval, and autonomous tool-using agents with a high-performance Material 3 Chat UI.
Flutter Local Agent Kit 🤖✨ #
The ultimate offline-first AI framework for Flutter. Build autonomous agents, private RAG systems, and high-performance chat interfaces that run 100% on-device.
🌟 Key Features #
- 🧠 High-Performance Inference: Native integration with
llamadartsupporting Llama 3.2, Gemma, and Mistral. - 🕵️ Autonomous Agents: Built-in ReAct (Reason-Act) loop for tool use (Calculators, APIs, System tasks).
- 📚 Private RAG: local vector database for knowledge injection without cloud dependencies.
- 🎨 Premium UI Components: 120Hz smooth
AgentChatViewwith Markdown, code blocks, and Suggestion Chips. - 🛡️ Secure & Private: No API keys, no data leaves the device. Perfect for privacy-first enterprise apps.
- ⚙️ Customizable Personas: Easily set custom system prompts for specialized agent behaviors.
🚀 Quick Start #
1. Initialize the Kit #
final kit = FlutterLocalAgentKit();
await kit.initialize(
modelPath: '/path/to/llama-3.2-1b.gguf',
systemPrompt: "You are a helpful coding assistant.",
);
2. Run an Autonomous Agent #
kit.runAgent("Calculate my tax for 50k salary and tell me the time.").listen((chunk) {
print(chunk); // Streams "Thought -> Action -> Observation -> Final Answer"
});
3. Use the Premium UI #
AgentChatView(
onMessage: (query) => kit.runAgent(query),
suggestions: const ['🕵️ Who are you?', '📅 Get Time', '🧮 Solve math'],
welcomeMessage: "Hello! I am your local AI agent.",
)
🛠️ Built-in Tools #
- Calculator: High-precision math execution.
- DateTime: Real-time context awareness.
- Custom Tools: Easily extend with
BaseTool.
📱 Performance (OnePlus 12) #
- Model: Llama 3.2 1B (Instruct)
- RAM Usage: ~900MB (Stable)
- Throughput: 45+ tokens/sec
- Latency: <100ms first-token (Native Vulkan/Impeller)
📄 License #
MIT License. Built with ❤️ for the Flutter Ecosystem (2026).