Quickstart Guide¶
CLI Usage¶
Initialize and manage configurations:
# Create starter configuration
llmling-agent init agents.yml
# Add to your configurations
llmling-agent add agents.yml
# Start chatting
llmling-agent chat assistant
Configured Agents¶
Create an agent configuration:
# agents.yml
agents:
assistant:
name: "Technical Assistant"
model: openai:gpt-5-mini
system_prompts:
- You are a helpful technical assistant.
toolsets:
- type: file_access
Use it in code:
from llmling_agent import AgentPool
async def main():
async with AgentPool("agents.yml") as pool:
agent = pool.get_agent("assistant")
response = await agent.run("What is Python?")
print(response.data)
if __name__ == "__main__":
import asyncio
asyncio.run(main())
Functional Interface¶
Quick model interactions without configuration:
from llmling_agent import run_with_model, run_with_model_sync
# Async usage
async def main():
# Simple completion
result = await run_with_model(
"Analyze this text",
model="openai:gpt-5-mini"
)
print(result)
# With structured output
from pydantic import BaseModel
class Analysis(BaseModel):
summary: str
key_points: list[str]
result = await run_with_model(
"Analyze the sentiment",
model="openai:gpt-5-mini",
output_type=Analysis
)
print(f"Summary: {result.summary}")
print(f"Key points: {result.key_points}")
# Sync usage (convenience wrapper)
result = run_with_model_sync(
"Quick question",
model="openai:gpt-5-mini"
)
Next Steps¶
- Learn about Key Concepts
- Explore Agent Configuration
- Try the Web Interface
- See Running Agents for more usage patterns
- Check the Command Reference for CLI options
Note
For details about environment configuration (tools, resources, etc.), see the LLMling documentation.