agno 2.3.4__py3-none-any.whl → 2.3.5__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (112) hide show
  1. agno/agent/agent.py +177 -41
  2. agno/culture/manager.py +2 -2
  3. agno/db/base.py +330 -8
  4. agno/db/dynamo/dynamo.py +722 -2
  5. agno/db/dynamo/schemas.py +127 -0
  6. agno/db/firestore/firestore.py +573 -1
  7. agno/db/firestore/schemas.py +40 -0
  8. agno/db/gcs_json/gcs_json_db.py +446 -1
  9. agno/db/in_memory/in_memory_db.py +143 -1
  10. agno/db/json/json_db.py +438 -1
  11. agno/db/mongo/async_mongo.py +522 -0
  12. agno/db/mongo/mongo.py +523 -1
  13. agno/db/mongo/schemas.py +29 -0
  14. agno/db/mysql/mysql.py +536 -3
  15. agno/db/mysql/schemas.py +38 -0
  16. agno/db/postgres/async_postgres.py +541 -13
  17. agno/db/postgres/postgres.py +535 -2
  18. agno/db/postgres/schemas.py +38 -0
  19. agno/db/redis/redis.py +468 -1
  20. agno/db/redis/schemas.py +32 -0
  21. agno/db/singlestore/schemas.py +38 -0
  22. agno/db/singlestore/singlestore.py +523 -1
  23. agno/db/sqlite/async_sqlite.py +548 -9
  24. agno/db/sqlite/schemas.py +38 -0
  25. agno/db/sqlite/sqlite.py +537 -5
  26. agno/db/sqlite/utils.py +6 -8
  27. agno/db/surrealdb/models.py +25 -0
  28. agno/db/surrealdb/surrealdb.py +548 -1
  29. agno/eval/accuracy.py +10 -4
  30. agno/eval/performance.py +10 -4
  31. agno/eval/reliability.py +22 -13
  32. agno/exceptions.py +11 -0
  33. agno/hooks/__init__.py +3 -0
  34. agno/hooks/decorator.py +164 -0
  35. agno/knowledge/chunking/semantic.py +2 -2
  36. agno/models/aimlapi/aimlapi.py +2 -3
  37. agno/models/anthropic/claude.py +18 -13
  38. agno/models/aws/bedrock.py +3 -4
  39. agno/models/aws/claude.py +5 -1
  40. agno/models/azure/ai_foundry.py +2 -2
  41. agno/models/azure/openai_chat.py +8 -0
  42. agno/models/cerebras/cerebras.py +63 -11
  43. agno/models/cerebras/cerebras_openai.py +2 -3
  44. agno/models/cohere/chat.py +1 -5
  45. agno/models/cometapi/cometapi.py +2 -3
  46. agno/models/dashscope/dashscope.py +2 -3
  47. agno/models/deepinfra/deepinfra.py +2 -3
  48. agno/models/deepseek/deepseek.py +2 -3
  49. agno/models/fireworks/fireworks.py +2 -3
  50. agno/models/google/gemini.py +9 -7
  51. agno/models/groq/groq.py +2 -3
  52. agno/models/huggingface/huggingface.py +1 -5
  53. agno/models/ibm/watsonx.py +1 -5
  54. agno/models/internlm/internlm.py +2 -3
  55. agno/models/langdb/langdb.py +6 -4
  56. agno/models/litellm/chat.py +2 -2
  57. agno/models/litellm/litellm_openai.py +2 -3
  58. agno/models/meta/llama.py +1 -5
  59. agno/models/meta/llama_openai.py +4 -5
  60. agno/models/mistral/mistral.py +1 -5
  61. agno/models/nebius/nebius.py +2 -3
  62. agno/models/nvidia/nvidia.py +4 -5
  63. agno/models/openai/chat.py +14 -3
  64. agno/models/openai/responses.py +14 -3
  65. agno/models/openrouter/openrouter.py +4 -5
  66. agno/models/perplexity/perplexity.py +2 -3
  67. agno/models/portkey/portkey.py +7 -6
  68. agno/models/requesty/requesty.py +4 -5
  69. agno/models/response.py +2 -1
  70. agno/models/sambanova/sambanova.py +4 -5
  71. agno/models/siliconflow/siliconflow.py +3 -4
  72. agno/models/together/together.py +4 -5
  73. agno/models/vercel/v0.py +4 -5
  74. agno/models/vllm/vllm.py +19 -14
  75. agno/models/xai/xai.py +4 -5
  76. agno/os/app.py +104 -0
  77. agno/os/config.py +13 -0
  78. agno/os/interfaces/whatsapp/router.py +0 -1
  79. agno/os/mcp.py +1 -0
  80. agno/os/router.py +31 -0
  81. agno/os/routers/traces/__init__.py +3 -0
  82. agno/os/routers/traces/schemas.py +414 -0
  83. agno/os/routers/traces/traces.py +499 -0
  84. agno/os/schema.py +10 -1
  85. agno/os/utils.py +57 -0
  86. agno/run/agent.py +1 -0
  87. agno/run/base.py +17 -0
  88. agno/run/team.py +4 -0
  89. agno/session/team.py +1 -0
  90. agno/table.py +10 -0
  91. agno/team/team.py +214 -65
  92. agno/tools/function.py +10 -8
  93. agno/tools/nano_banana.py +1 -1
  94. agno/tracing/__init__.py +12 -0
  95. agno/tracing/exporter.py +157 -0
  96. agno/tracing/schemas.py +276 -0
  97. agno/tracing/setup.py +111 -0
  98. agno/utils/agent.py +4 -4
  99. agno/utils/hooks.py +56 -1
  100. agno/vectordb/qdrant/qdrant.py +22 -22
  101. agno/workflow/condition.py +8 -0
  102. agno/workflow/loop.py +8 -0
  103. agno/workflow/parallel.py +8 -0
  104. agno/workflow/router.py +8 -0
  105. agno/workflow/step.py +20 -0
  106. agno/workflow/steps.py +8 -0
  107. agno/workflow/workflow.py +83 -17
  108. {agno-2.3.4.dist-info → agno-2.3.5.dist-info}/METADATA +2 -2
  109. {agno-2.3.4.dist-info → agno-2.3.5.dist-info}/RECORD +112 -102
  110. {agno-2.3.4.dist-info → agno-2.3.5.dist-info}/WHEEL +0 -0
  111. {agno-2.3.4.dist-info → agno-2.3.5.dist-info}/licenses/LICENSE +0 -0
  112. {agno-2.3.4.dist-info → agno-2.3.5.dist-info}/top_level.txt +0 -0
agno/db/dynamo/schemas.py CHANGED
@@ -114,6 +114,15 @@ USER_MEMORY_TABLE_SCHEMA = {
114
114
  "Projection": {"ProjectionType": "ALL"},
115
115
  "ProvisionedThroughput": {"ReadCapacityUnits": 5, "WriteCapacityUnits": 5},
116
116
  },
117
+ {
118
+ "IndexName": "workflow_id-created_at-index",
119
+ "KeySchema": [
120
+ {"AttributeName": "workflow_id", "KeyType": "HASH"},
121
+ {"AttributeName": "created_at", "KeyType": "RANGE"},
122
+ ],
123
+ "Projection": {"ProjectionType": "ALL"},
124
+ "ProvisionedThroughput": {"ReadCapacityUnits": 5, "WriteCapacityUnits": 5},
125
+ },
117
126
  ],
118
127
  "BillingMode": "PROVISIONED",
119
128
  "ProvisionedThroughput": {"ReadCapacityUnits": 5, "WriteCapacityUnits": 5},
@@ -288,6 +297,122 @@ CULTURAL_KNOWLEDGE_TABLE_SCHEMA = {
288
297
  "ProvisionedThroughput": {"ReadCapacityUnits": 5, "WriteCapacityUnits": 5},
289
298
  }
290
299
 
300
+ TRACE_TABLE_SCHEMA = {
301
+ "TableName": "agno_traces",
302
+ "KeySchema": [{"AttributeName": "trace_id", "KeyType": "HASH"}],
303
+ "AttributeDefinitions": [
304
+ {"AttributeName": "trace_id", "AttributeType": "S"},
305
+ {"AttributeName": "run_id", "AttributeType": "S"},
306
+ {"AttributeName": "session_id", "AttributeType": "S"},
307
+ {"AttributeName": "user_id", "AttributeType": "S"},
308
+ {"AttributeName": "agent_id", "AttributeType": "S"},
309
+ {"AttributeName": "team_id", "AttributeType": "S"},
310
+ {"AttributeName": "workflow_id", "AttributeType": "S"},
311
+ {"AttributeName": "status", "AttributeType": "S"},
312
+ {"AttributeName": "start_time", "AttributeType": "S"},
313
+ ],
314
+ "GlobalSecondaryIndexes": [
315
+ {
316
+ "IndexName": "run_id-start_time-index",
317
+ "KeySchema": [
318
+ {"AttributeName": "run_id", "KeyType": "HASH"},
319
+ {"AttributeName": "start_time", "KeyType": "RANGE"},
320
+ ],
321
+ "Projection": {"ProjectionType": "ALL"},
322
+ "ProvisionedThroughput": {"ReadCapacityUnits": 5, "WriteCapacityUnits": 5},
323
+ },
324
+ {
325
+ "IndexName": "session_id-start_time-index",
326
+ "KeySchema": [
327
+ {"AttributeName": "session_id", "KeyType": "HASH"},
328
+ {"AttributeName": "start_time", "KeyType": "RANGE"},
329
+ ],
330
+ "Projection": {"ProjectionType": "ALL"},
331
+ "ProvisionedThroughput": {"ReadCapacityUnits": 5, "WriteCapacityUnits": 5},
332
+ },
333
+ {
334
+ "IndexName": "user_id-start_time-index",
335
+ "KeySchema": [
336
+ {"AttributeName": "user_id", "KeyType": "HASH"},
337
+ {"AttributeName": "start_time", "KeyType": "RANGE"},
338
+ ],
339
+ "Projection": {"ProjectionType": "ALL"},
340
+ "ProvisionedThroughput": {"ReadCapacityUnits": 5, "WriteCapacityUnits": 5},
341
+ },
342
+ {
343
+ "IndexName": "agent_id-start_time-index",
344
+ "KeySchema": [
345
+ {"AttributeName": "agent_id", "KeyType": "HASH"},
346
+ {"AttributeName": "start_time", "KeyType": "RANGE"},
347
+ ],
348
+ "Projection": {"ProjectionType": "ALL"},
349
+ "ProvisionedThroughput": {"ReadCapacityUnits": 5, "WriteCapacityUnits": 5},
350
+ },
351
+ {
352
+ "IndexName": "team_id-start_time-index",
353
+ "KeySchema": [
354
+ {"AttributeName": "team_id", "KeyType": "HASH"},
355
+ {"AttributeName": "start_time", "KeyType": "RANGE"},
356
+ ],
357
+ "Projection": {"ProjectionType": "ALL"},
358
+ "ProvisionedThroughput": {"ReadCapacityUnits": 5, "WriteCapacityUnits": 5},
359
+ },
360
+ {
361
+ "IndexName": "workflow_id-start_time-index",
362
+ "KeySchema": [
363
+ {"AttributeName": "workflow_id", "KeyType": "HASH"},
364
+ {"AttributeName": "start_time", "KeyType": "RANGE"},
365
+ ],
366
+ "Projection": {"ProjectionType": "ALL"},
367
+ "ProvisionedThroughput": {"ReadCapacityUnits": 5, "WriteCapacityUnits": 5},
368
+ },
369
+ {
370
+ "IndexName": "status-start_time-index",
371
+ "KeySchema": [
372
+ {"AttributeName": "status", "KeyType": "HASH"},
373
+ {"AttributeName": "start_time", "KeyType": "RANGE"},
374
+ ],
375
+ "Projection": {"ProjectionType": "ALL"},
376
+ "ProvisionedThroughput": {"ReadCapacityUnits": 5, "WriteCapacityUnits": 5},
377
+ },
378
+ ],
379
+ "BillingMode": "PROVISIONED",
380
+ "ProvisionedThroughput": {"ReadCapacityUnits": 5, "WriteCapacityUnits": 5},
381
+ }
382
+
383
+ SPAN_TABLE_SCHEMA = {
384
+ "TableName": "agno_spans",
385
+ "KeySchema": [{"AttributeName": "span_id", "KeyType": "HASH"}],
386
+ "AttributeDefinitions": [
387
+ {"AttributeName": "span_id", "AttributeType": "S"},
388
+ {"AttributeName": "trace_id", "AttributeType": "S"},
389
+ {"AttributeName": "parent_span_id", "AttributeType": "S"},
390
+ {"AttributeName": "start_time", "AttributeType": "S"},
391
+ ],
392
+ "GlobalSecondaryIndexes": [
393
+ {
394
+ "IndexName": "trace_id-start_time-index",
395
+ "KeySchema": [
396
+ {"AttributeName": "trace_id", "KeyType": "HASH"},
397
+ {"AttributeName": "start_time", "KeyType": "RANGE"},
398
+ ],
399
+ "Projection": {"ProjectionType": "ALL"},
400
+ "ProvisionedThroughput": {"ReadCapacityUnits": 5, "WriteCapacityUnits": 5},
401
+ },
402
+ {
403
+ "IndexName": "parent_span_id-start_time-index",
404
+ "KeySchema": [
405
+ {"AttributeName": "parent_span_id", "KeyType": "HASH"},
406
+ {"AttributeName": "start_time", "KeyType": "RANGE"},
407
+ ],
408
+ "Projection": {"ProjectionType": "ALL"},
409
+ "ProvisionedThroughput": {"ReadCapacityUnits": 5, "WriteCapacityUnits": 5},
410
+ },
411
+ ],
412
+ "BillingMode": "PROVISIONED",
413
+ "ProvisionedThroughput": {"ReadCapacityUnits": 5, "WriteCapacityUnits": 5},
414
+ }
415
+
291
416
 
292
417
  def get_table_schema_definition(table_type: str) -> Dict[str, Any]:
293
418
  """
@@ -306,6 +431,8 @@ def get_table_schema_definition(table_type: str) -> Dict[str, Any]:
306
431
  "knowledge": KNOWLEDGE_TABLE_SCHEMA,
307
432
  "metrics": METRICS_TABLE_SCHEMA,
308
433
  "culture": CULTURAL_KNOWLEDGE_TABLE_SCHEMA,
434
+ "traces": TRACE_TABLE_SCHEMA,
435
+ "spans": SPAN_TABLE_SCHEMA,
309
436
  }
310
437
 
311
438
  schema = schemas.get(table_type, {})