camel-ai 0.2.82__py3-none-any.whl → 0.2.83a6__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.
Potentially problematic release.
This version of camel-ai might be problematic. Click here for more details.
- camel/__init__.py +3 -3
- camel/agents/__init__.py +2 -2
- camel/agents/_types.py +2 -2
- camel/agents/_utils.py +2 -2
- camel/agents/base.py +2 -2
- camel/agents/chat_agent.py +765 -541
- camel/agents/critic_agent.py +2 -2
- camel/agents/deductive_reasoner_agent.py +2 -2
- camel/agents/embodied_agent.py +2 -2
- camel/agents/knowledge_graph_agent.py +2 -2
- camel/agents/mcp_agent.py +2 -2
- camel/agents/multi_hop_generator_agent.py +2 -2
- camel/agents/programmed_agent_instruction.py +2 -2
- camel/agents/repo_agent.py +2 -2
- camel/agents/role_assignment_agent.py +2 -2
- camel/agents/search_agent.py +2 -2
- camel/agents/task_agent.py +2 -2
- camel/agents/tool_agents/__init__.py +2 -2
- camel/agents/tool_agents/base.py +2 -2
- camel/agents/tool_agents/hugging_face_tool_agent.py +2 -2
- camel/benchmarks/__init__.py +2 -2
- camel/benchmarks/apibank.py +2 -2
- camel/benchmarks/apibench.py +2 -2
- camel/benchmarks/base.py +2 -2
- camel/benchmarks/browsecomp.py +2 -2
- camel/benchmarks/gaia.py +2 -2
- camel/benchmarks/mock_website/mock_web.py +2 -2
- camel/benchmarks/mock_website/shopping_mall/app.py +2 -2
- camel/benchmarks/nexus.py +2 -2
- camel/benchmarks/ragbench.py +2 -2
- camel/bots/__init__.py +2 -2
- camel/bots/discord/__init__.py +2 -2
- camel/bots/discord/discord_app.py +2 -2
- camel/bots/discord/discord_installation.py +2 -2
- camel/bots/discord/discord_store.py +2 -2
- camel/bots/slack/__init__.py +2 -2
- camel/bots/slack/models.py +2 -2
- camel/bots/slack/slack_app.py +2 -2
- camel/bots/telegram_bot.py +2 -2
- camel/configs/__init__.py +8 -2
- camel/configs/aihubmix_config.py +2 -2
- camel/configs/aiml_config.py +2 -2
- camel/configs/amd_config.py +2 -2
- camel/configs/anthropic_config.py +2 -2
- camel/configs/base_config.py +2 -2
- camel/configs/bedrock_config.py +2 -2
- camel/configs/cerebras_config.py +2 -2
- camel/configs/cohere_config.py +2 -2
- camel/configs/cometapi_config.py +2 -2
- camel/configs/crynux_config.py +2 -2
- camel/configs/deepseek_config.py +2 -2
- camel/configs/function_gemma_config.py +59 -0
- camel/configs/gemini_config.py +2 -2
- camel/configs/groq_config.py +2 -2
- camel/configs/internlm_config.py +2 -2
- camel/configs/litellm_config.py +2 -2
- camel/configs/lmstudio_config.py +2 -2
- camel/configs/minimax_config.py +2 -2
- camel/configs/mistral_config.py +2 -2
- camel/configs/modelscope_config.py +2 -2
- camel/configs/moonshot_config.py +2 -2
- camel/configs/nebius_config.py +2 -2
- camel/configs/netmind_config.py +2 -2
- camel/configs/novita_config.py +2 -2
- camel/configs/nvidia_config.py +2 -2
- camel/configs/ollama_config.py +2 -2
- camel/configs/openai_config.py +2 -2
- camel/configs/openrouter_config.py +2 -2
- camel/configs/ppio_config.py +2 -2
- camel/configs/qianfan_config.py +2 -2
- camel/configs/qwen_config.py +2 -2
- camel/configs/reka_config.py +2 -2
- camel/configs/samba_config.py +2 -2
- camel/configs/sglang_config.py +2 -2
- camel/configs/siliconflow_config.py +2 -2
- camel/configs/togetherai_config.py +2 -2
- camel/configs/vllm_config.py +2 -2
- camel/configs/watsonx_config.py +2 -2
- camel/configs/yi_config.py +2 -2
- camel/configs/zhipuai_config.py +2 -2
- camel/data_collectors/__init__.py +2 -2
- camel/data_collectors/alpaca_collector.py +2 -2
- camel/data_collectors/base.py +2 -2
- camel/data_collectors/sharegpt_collector.py +2 -2
- camel/datagen/__init__.py +2 -2
- camel/datagen/cot_datagen.py +2 -2
- camel/datagen/evol_instruct/__init__.py +2 -2
- camel/datagen/evol_instruct/evol_instruct.py +2 -2
- camel/datagen/evol_instruct/scorer.py +2 -2
- camel/datagen/evol_instruct/templates.py +2 -2
- camel/datagen/self_improving_cot.py +2 -2
- camel/datagen/self_instruct/__init__.py +2 -2
- camel/datagen/self_instruct/filter/__init__.py +2 -2
- camel/datagen/self_instruct/filter/filter_function.py +2 -2
- camel/datagen/self_instruct/filter/filter_registry.py +2 -2
- camel/datagen/self_instruct/filter/instruction_filter.py +2 -2
- camel/datagen/self_instruct/self_instruct.py +2 -2
- camel/datagen/self_instruct/templates.py +2 -2
- camel/datagen/source2synth/__init__.py +2 -2
- camel/datagen/source2synth/data_processor.py +2 -2
- camel/datagen/source2synth/models.py +2 -2
- camel/datagen/source2synth/user_data_processor_config.py +2 -2
- camel/datahubs/__init__.py +2 -2
- camel/datahubs/base.py +2 -2
- camel/datahubs/huggingface.py +2 -2
- camel/datahubs/models.py +2 -2
- camel/datasets/__init__.py +2 -2
- camel/datasets/base_generator.py +2 -2
- camel/datasets/few_shot_generator.py +2 -2
- camel/datasets/models.py +2 -2
- camel/datasets/self_instruct_generator.py +2 -2
- camel/datasets/static_dataset.py +2 -2
- camel/embeddings/__init__.py +2 -2
- camel/embeddings/azure_embedding.py +2 -2
- camel/embeddings/base.py +2 -2
- camel/embeddings/gemini_embedding.py +2 -2
- camel/embeddings/jina_embedding.py +2 -2
- camel/embeddings/mistral_embedding.py +2 -2
- camel/embeddings/openai_compatible_embedding.py +2 -2
- camel/embeddings/openai_embedding.py +2 -2
- camel/embeddings/sentence_transformers_embeddings.py +2 -2
- camel/embeddings/together_embedding.py +2 -2
- camel/embeddings/vlm_embedding.py +2 -2
- camel/environments/__init__.py +2 -2
- camel/environments/models.py +2 -2
- camel/environments/multi_step.py +2 -2
- camel/environments/rlcards_env.py +2 -2
- camel/environments/single_step.py +2 -2
- camel/environments/tic_tac_toe.py +2 -2
- camel/extractors/__init__.py +2 -2
- camel/extractors/base.py +2 -2
- camel/extractors/python_strategies.py +2 -2
- camel/generators.py +2 -2
- camel/human.py +2 -2
- camel/interpreters/__init__.py +2 -2
- camel/interpreters/base.py +2 -2
- camel/interpreters/docker_interpreter.py +2 -2
- camel/interpreters/e2b_interpreter.py +2 -2
- camel/interpreters/internal_python_interpreter.py +2 -2
- camel/interpreters/interpreter_error.py +2 -2
- camel/interpreters/ipython_interpreter.py +2 -2
- camel/interpreters/microsandbox_interpreter.py +2 -2
- camel/interpreters/subprocess_interpreter.py +2 -2
- camel/loaders/__init__.py +2 -2
- camel/loaders/apify_reader.py +2 -2
- camel/loaders/base_io.py +2 -2
- camel/loaders/base_loader.py +2 -2
- camel/loaders/chunkr_reader.py +2 -2
- camel/loaders/crawl4ai_reader.py +2 -2
- camel/loaders/firecrawl_reader.py +2 -2
- camel/loaders/jina_url_reader.py +2 -2
- camel/loaders/markitdown.py +2 -2
- camel/loaders/mineru_extractor.py +2 -2
- camel/loaders/mistral_reader.py +2 -2
- camel/loaders/scrapegraph_reader.py +2 -2
- camel/loaders/unstructured_io.py +2 -2
- camel/logger.py +2 -2
- camel/memories/__init__.py +2 -2
- camel/memories/agent_memories.py +2 -2
- camel/memories/base.py +2 -2
- camel/memories/blocks/__init__.py +2 -2
- camel/memories/blocks/chat_history_block.py +2 -2
- camel/memories/blocks/vectordb_block.py +2 -2
- camel/memories/context_creators/__init__.py +2 -2
- camel/memories/context_creators/score_based.py +89 -2
- camel/memories/records.py +2 -2
- camel/messages/__init__.py +2 -2
- camel/messages/base.py +2 -2
- camel/messages/conversion/__init__.py +2 -2
- camel/messages/conversion/alpaca.py +2 -2
- camel/messages/conversion/conversation_models.py +2 -2
- camel/messages/conversion/sharegpt/__init__.py +2 -2
- camel/messages/conversion/sharegpt/function_call_formatter.py +2 -2
- camel/messages/conversion/sharegpt/hermes/__init__.py +2 -2
- camel/messages/conversion/sharegpt/hermes/hermes_function_formatter.py +2 -2
- camel/messages/func_message.py +2 -2
- camel/models/__init__.py +4 -2
- camel/models/_utils.py +2 -2
- camel/models/aihubmix_model.py +2 -2
- camel/models/aiml_model.py +2 -2
- camel/models/amd_model.py +2 -2
- camel/models/anthropic_model.py +2 -2
- camel/models/aws_bedrock_model.py +2 -2
- camel/models/azure_openai_model.py +4 -28
- camel/models/base_audio_model.py +2 -2
- camel/models/base_model.py +192 -14
- camel/models/cerebras_model.py +2 -2
- camel/models/cohere_model.py +4 -30
- camel/models/cometapi_model.py +2 -2
- camel/models/crynux_model.py +2 -2
- camel/models/deepseek_model.py +4 -28
- camel/models/fish_audio_model.py +2 -2
- camel/models/function_gemma_model.py +889 -0
- camel/models/gemini_model.py +4 -28
- camel/models/groq_model.py +2 -2
- camel/models/internlm_model.py +2 -2
- camel/models/litellm_model.py +3 -17
- camel/models/lmstudio_model.py +2 -2
- camel/models/minimax_model.py +2 -2
- camel/models/mistral_model.py +4 -30
- camel/models/model_factory.py +4 -2
- camel/models/model_manager.py +2 -2
- camel/models/modelscope_model.py +2 -2
- camel/models/moonshot_model.py +3 -15
- camel/models/nebius_model.py +2 -2
- camel/models/nemotron_model.py +2 -2
- camel/models/netmind_model.py +2 -2
- camel/models/novita_model.py +2 -2
- camel/models/nvidia_model.py +2 -2
- camel/models/ollama_model.py +2 -2
- camel/models/openai_audio_models.py +2 -2
- camel/models/openai_compatible_model.py +4 -28
- camel/models/openai_model.py +4 -43
- camel/models/openrouter_model.py +2 -2
- camel/models/ppio_model.py +2 -2
- camel/models/qianfan_model.py +2 -2
- camel/models/qwen_model.py +2 -2
- camel/models/reka_model.py +4 -30
- camel/models/reward/__init__.py +2 -2
- camel/models/reward/base_reward_model.py +2 -2
- camel/models/reward/evaluator.py +2 -2
- camel/models/reward/nemotron_model.py +2 -2
- camel/models/reward/skywork_model.py +2 -2
- camel/models/samba_model.py +4 -30
- camel/models/sglang_model.py +4 -30
- camel/models/siliconflow_model.py +2 -2
- camel/models/stub_model.py +2 -2
- camel/models/togetherai_model.py +2 -2
- camel/models/vllm_model.py +2 -2
- camel/models/volcano_model.py +147 -4
- camel/models/watsonx_model.py +4 -30
- camel/models/yi_model.py +2 -2
- camel/models/zhipuai_model.py +2 -2
- camel/parsers/__init__.py +2 -2
- camel/parsers/mcp_tool_call_parser.py +2 -2
- camel/personas/__init__.py +2 -2
- camel/personas/persona.py +2 -2
- camel/personas/persona_hub.py +2 -2
- camel/prompts/__init__.py +2 -2
- camel/prompts/ai_society.py +2 -2
- camel/prompts/base.py +2 -2
- camel/prompts/code.py +2 -2
- camel/prompts/evaluation.py +2 -2
- camel/prompts/generate_text_embedding_data.py +2 -2
- camel/prompts/image_craft.py +2 -2
- camel/prompts/misalignment.py +2 -2
- camel/prompts/multi_condition_image_craft.py +2 -2
- camel/prompts/object_recognition.py +2 -2
- camel/prompts/persona_hub.py +2 -2
- camel/prompts/prompt_templates.py +2 -2
- camel/prompts/role_description_prompt_template.py +2 -2
- camel/prompts/solution_extraction.py +2 -2
- camel/prompts/task_prompt_template.py +2 -2
- camel/prompts/translation.py +2 -2
- camel/prompts/video_description_prompt.py +2 -2
- camel/responses/__init__.py +2 -2
- camel/responses/agent_responses.py +2 -2
- camel/retrievers/__init__.py +2 -2
- camel/retrievers/auto_retriever.py +2 -2
- camel/retrievers/base.py +2 -2
- camel/retrievers/bm25_retriever.py +2 -2
- camel/retrievers/cohere_rerank_retriever.py +2 -2
- camel/retrievers/hybrid_retrival.py +2 -2
- camel/retrievers/vector_retriever.py +2 -2
- camel/runtimes/__init__.py +2 -2
- camel/runtimes/api.py +2 -2
- camel/runtimes/base.py +2 -2
- camel/runtimes/configs.py +2 -2
- camel/runtimes/daytona_runtime.py +2 -2
- camel/runtimes/docker_runtime.py +2 -2
- camel/runtimes/llm_guard_runtime.py +2 -2
- camel/runtimes/remote_http_runtime.py +2 -2
- camel/runtimes/ubuntu_docker_runtime.py +2 -2
- camel/runtimes/utils/__init__.py +2 -2
- camel/runtimes/utils/function_risk_toolkit.py +2 -2
- camel/runtimes/utils/ignore_risk_toolkit.py +2 -2
- camel/schemas/__init__.py +2 -2
- camel/schemas/base.py +2 -2
- camel/schemas/openai_converter.py +2 -2
- camel/schemas/outlines_converter.py +2 -2
- camel/services/agent_openapi_server.py +2 -2
- camel/societies/__init__.py +2 -2
- camel/societies/babyagi_playing.py +2 -2
- camel/societies/role_playing.py +2 -2
- camel/societies/workforce/__init__.py +2 -2
- camel/societies/workforce/base.py +2 -2
- camel/societies/workforce/events.py +4 -2
- camel/societies/workforce/prompts.py +9 -8
- camel/societies/workforce/role_playing_worker.py +2 -2
- camel/societies/workforce/single_agent_worker.py +2 -2
- camel/societies/workforce/structured_output_handler.py +2 -2
- camel/societies/workforce/task_channel.py +2 -2
- camel/societies/workforce/utils.py +2 -2
- camel/societies/workforce/worker.py +2 -2
- camel/societies/workforce/workflow_memory_manager.py +2 -2
- camel/societies/workforce/workforce.py +132 -71
- camel/societies/workforce/workforce_callback.py +2 -2
- camel/societies/workforce/workforce_logger.py +2 -2
- camel/societies/workforce/workforce_metrics.py +2 -2
- camel/storages/__init__.py +2 -2
- camel/storages/graph_storages/__init__.py +2 -2
- camel/storages/graph_storages/base.py +2 -2
- camel/storages/graph_storages/graph_element.py +2 -2
- camel/storages/graph_storages/nebula_graph.py +2 -2
- camel/storages/graph_storages/neo4j_graph.py +2 -2
- camel/storages/key_value_storages/__init__.py +2 -2
- camel/storages/key_value_storages/base.py +2 -2
- camel/storages/key_value_storages/in_memory.py +2 -2
- camel/storages/key_value_storages/json.py +2 -2
- camel/storages/key_value_storages/mem0_cloud.py +2 -2
- camel/storages/key_value_storages/redis.py +2 -2
- camel/storages/object_storages/__init__.py +2 -2
- camel/storages/object_storages/amazon_s3.py +2 -2
- camel/storages/object_storages/azure_blob.py +2 -2
- camel/storages/object_storages/base.py +2 -2
- camel/storages/object_storages/google_cloud.py +2 -2
- camel/storages/vectordb_storages/__init__.py +2 -2
- camel/storages/vectordb_storages/base.py +2 -2
- camel/storages/vectordb_storages/chroma.py +2 -2
- camel/storages/vectordb_storages/faiss.py +2 -2
- camel/storages/vectordb_storages/milvus.py +2 -2
- camel/storages/vectordb_storages/oceanbase.py +2 -2
- camel/storages/vectordb_storages/pgvector.py +2 -2
- camel/storages/vectordb_storages/qdrant.py +2 -2
- camel/storages/vectordb_storages/surreal.py +2 -2
- camel/storages/vectordb_storages/tidb.py +2 -2
- camel/storages/vectordb_storages/weaviate.py +2 -2
- camel/tasks/__init__.py +2 -2
- camel/tasks/task.py +2 -2
- camel/tasks/task_prompt.py +2 -2
- camel/terminators/__init__.py +2 -2
- camel/terminators/base.py +2 -2
- camel/terminators/response_terminator.py +2 -2
- camel/terminators/token_limit_terminator.py +2 -2
- camel/toolkits/__init__.py +6 -3
- camel/toolkits/aci_toolkit.py +2 -2
- camel/toolkits/arxiv_toolkit.py +2 -2
- camel/toolkits/ask_news_toolkit.py +2 -2
- camel/toolkits/async_browser_toolkit.py +2 -2
- camel/toolkits/audio_analysis_toolkit.py +2 -2
- camel/toolkits/base.py +47 -5
- camel/toolkits/bohrium_toolkit.py +2 -2
- camel/toolkits/browser_toolkit.py +2 -2
- camel/toolkits/browser_toolkit_commons.py +2 -2
- camel/toolkits/code_execution.py +2 -2
- camel/toolkits/context_summarizer_toolkit.py +2 -2
- camel/toolkits/craw4ai_toolkit.py +2 -2
- camel/toolkits/dappier_toolkit.py +2 -2
- camel/toolkits/data_commons_toolkit.py +2 -2
- camel/toolkits/dingtalk.py +2 -2
- camel/toolkits/earth_science_toolkit.py +2 -2
- camel/toolkits/edgeone_pages_mcp_toolkit.py +2 -2
- camel/toolkits/excel_toolkit.py +2 -2
- camel/toolkits/file_toolkit.py +2 -2
- camel/toolkits/function_tool.py +95 -25
- camel/toolkits/github_toolkit.py +2 -2
- camel/toolkits/gmail_toolkit.py +2 -2
- camel/toolkits/google_calendar_toolkit.py +2 -2
- camel/toolkits/google_drive_mcp_toolkit.py +2 -2
- camel/toolkits/google_maps_toolkit.py +2 -2
- camel/toolkits/google_scholar_toolkit.py +2 -2
- camel/toolkits/human_toolkit.py +2 -2
- camel/toolkits/hybrid_browser_toolkit/__init__.py +2 -2
- camel/toolkits/hybrid_browser_toolkit/config_loader.py +2 -2
- camel/toolkits/hybrid_browser_toolkit/hybrid_browser_toolkit.py +2 -2
- camel/toolkits/hybrid_browser_toolkit/hybrid_browser_toolkit_ts.py +89 -104
- camel/toolkits/hybrid_browser_toolkit/installer.py +2 -2
- camel/toolkits/hybrid_browser_toolkit/ts/src/browser-session.ts +25 -14
- camel/toolkits/hybrid_browser_toolkit/ts/websocket-server.js +6 -0
- camel/toolkits/hybrid_browser_toolkit/ws_wrapper.py +2 -2
- camel/toolkits/hybrid_browser_toolkit_py/__init__.py +2 -2
- camel/toolkits/hybrid_browser_toolkit_py/actions.py +2 -2
- camel/toolkits/hybrid_browser_toolkit_py/agent.py +2 -2
- camel/toolkits/hybrid_browser_toolkit_py/browser_session.py +2 -2
- camel/toolkits/hybrid_browser_toolkit_py/config_loader.py +2 -2
- camel/toolkits/hybrid_browser_toolkit_py/hybrid_browser_toolkit.py +2 -2
- camel/toolkits/hybrid_browser_toolkit_py/snapshot.py +2 -2
- camel/toolkits/image_analysis_toolkit.py +2 -2
- camel/toolkits/image_generation_toolkit.py +2 -2
- camel/toolkits/jina_reranker_toolkit.py +2 -2
- camel/toolkits/klavis_toolkit.py +2 -2
- camel/toolkits/linkedin_toolkit.py +2 -2
- camel/toolkits/markitdown_toolkit.py +2 -2
- camel/toolkits/math_toolkit.py +2 -2
- camel/toolkits/mcp_toolkit.py +2 -2
- camel/toolkits/memory_toolkit.py +2 -2
- camel/toolkits/meshy_toolkit.py +2 -2
- camel/toolkits/message_agent_toolkit.py +2 -2
- camel/toolkits/message_integration.py +6 -2
- camel/toolkits/microsoft_outlook_mail_toolkit.py +1885 -0
- camel/toolkits/mineru_toolkit.py +2 -2
- camel/toolkits/minimax_mcp_toolkit.py +2 -2
- camel/toolkits/networkx_toolkit.py +2 -2
- camel/toolkits/note_taking_toolkit.py +2 -2
- camel/toolkits/notion_mcp_toolkit.py +2 -2
- camel/toolkits/notion_toolkit.py +2 -2
- camel/toolkits/open_api_specs/biztoc/__init__.py +2 -2
- camel/toolkits/open_api_specs/coursera/__init__.py +2 -2
- camel/toolkits/open_api_specs/create_qr_code/__init__.py +2 -2
- camel/toolkits/open_api_specs/klarna/__init__.py +2 -2
- camel/toolkits/open_api_specs/nasa_apod/__init__.py +2 -2
- camel/toolkits/open_api_specs/outschool/__init__.py +2 -2
- camel/toolkits/open_api_specs/outschool/paths/__init__.py +2 -2
- camel/toolkits/open_api_specs/outschool/paths/get_classes.py +2 -2
- camel/toolkits/open_api_specs/outschool/paths/search_teachers.py +2 -2
- camel/toolkits/open_api_specs/security_config.py +2 -2
- camel/toolkits/open_api_specs/speak/__init__.py +2 -2
- camel/toolkits/open_api_specs/web_scraper/__init__.py +2 -2
- camel/toolkits/open_api_specs/web_scraper/paths/__init__.py +2 -2
- camel/toolkits/open_api_specs/web_scraper/paths/scraper.py +2 -2
- camel/toolkits/open_api_toolkit.py +2 -2
- camel/toolkits/openbb_toolkit.py +2 -2
- camel/toolkits/origene_mcp_toolkit.py +2 -2
- camel/toolkits/playwright_mcp_toolkit.py +2 -2
- camel/toolkits/pptx_toolkit.py +2 -2
- camel/toolkits/pubmed_toolkit.py +2 -2
- camel/toolkits/pulse_mcp_search_toolkit.py +2 -2
- camel/toolkits/pyautogui_toolkit.py +2 -2
- camel/toolkits/reddit_toolkit.py +2 -2
- camel/toolkits/resend_toolkit.py +2 -2
- camel/toolkits/retrieval_toolkit.py +2 -2
- camel/toolkits/screenshot_toolkit.py +2 -2
- camel/toolkits/search_toolkit.py +70 -13
- camel/toolkits/searxng_toolkit.py +2 -2
- camel/toolkits/semantic_scholar_toolkit.py +2 -2
- camel/toolkits/slack_toolkit.py +2 -2
- camel/toolkits/sql_toolkit.py +2 -2
- camel/toolkits/stripe_toolkit.py +2 -2
- camel/toolkits/sympy_toolkit.py +2 -2
- camel/toolkits/task_planning_toolkit.py +2 -2
- camel/toolkits/terminal_toolkit/__init__.py +2 -2
- camel/toolkits/terminal_toolkit/terminal_toolkit.py +323 -112
- camel/toolkits/terminal_toolkit/utils.py +179 -52
- camel/toolkits/thinking_toolkit.py +2 -2
- camel/toolkits/twitter_toolkit.py +2 -2
- camel/toolkits/vertex_ai_veo_toolkit.py +2 -2
- camel/toolkits/video_analysis_toolkit.py +2 -2
- camel/toolkits/video_download_toolkit.py +2 -2
- camel/toolkits/weather_toolkit.py +2 -2
- camel/toolkits/web_deploy_toolkit.py +2 -2
- camel/toolkits/wechat_official_toolkit.py +2 -2
- camel/toolkits/whatsapp_toolkit.py +2 -2
- camel/toolkits/wolfram_alpha_toolkit.py +2 -2
- camel/toolkits/zapier_toolkit.py +2 -2
- camel/types/__init__.py +2 -2
- camel/types/agents/__init__.py +2 -2
- camel/types/agents/tool_calling_record.py +2 -2
- camel/types/enums.py +5 -4
- camel/types/mcp_registries.py +2 -2
- camel/types/openai_types.py +2 -2
- camel/types/unified_model_type.py +10 -6
- camel/utils/__init__.py +5 -2
- camel/utils/agent_context.py +41 -0
- camel/utils/async_func.py +2 -2
- camel/utils/chunker/__init__.py +2 -2
- camel/utils/chunker/base.py +2 -2
- camel/utils/chunker/code_chunker.py +2 -2
- camel/utils/chunker/uio_chunker.py +2 -2
- camel/utils/commons.py +2 -2
- camel/utils/constants.py +2 -2
- camel/utils/context_utils.py +2 -2
- camel/utils/deduplication.py +2 -2
- camel/utils/filename.py +2 -2
- camel/utils/langfuse.py +18 -10
- camel/utils/mcp.py +2 -2
- camel/utils/mcp_client.py +2 -2
- camel/utils/message_summarizer.py +2 -2
- camel/utils/response_format.py +2 -2
- camel/utils/token_counting.py +2 -2
- camel/utils/tool_result.py +2 -2
- camel/verifiers/__init__.py +2 -2
- camel/verifiers/base.py +2 -2
- camel/verifiers/math_verifier.py +2 -2
- camel/verifiers/models.py +2 -2
- camel/verifiers/physics_verifier.py +2 -2
- camel/verifiers/python_verifier.py +2 -2
- {camel_ai-0.2.82.dist-info → camel_ai-0.2.83a6.dist-info}/METADATA +34 -29
- camel_ai-0.2.83a6.dist-info/RECORD +511 -0
- camel_ai-0.2.82.dist-info/RECORD +0 -507
- {camel_ai-0.2.82.dist-info → camel_ai-0.2.83a6.dist-info}/WHEEL +0 -0
- {camel_ai-0.2.82.dist-info → camel_ai-0.2.83a6.dist-info}/licenses/LICENSE +0 -0
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# ========= Copyright 2023-
|
|
1
|
+
# ========= Copyright 2023-2026 @ CAMEL-AI.org. All Rights Reserved. =========
|
|
2
2
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
|
3
3
|
# you may not use this file except in compliance with the License.
|
|
4
4
|
# You may obtain a copy of the License at
|
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
11
11
|
# See the License for the specific language governing permissions and
|
|
12
12
|
# limitations under the License.
|
|
13
|
-
# ========= Copyright 2023-
|
|
13
|
+
# ========= Copyright 2023-2026 @ CAMEL-AI.org. All Rights Reserved. =========
|
|
14
14
|
|
|
15
15
|
import os
|
|
16
16
|
import platform
|
|
@@ -18,6 +18,7 @@ import re
|
|
|
18
18
|
import shutil
|
|
19
19
|
import subprocess
|
|
20
20
|
import sys
|
|
21
|
+
import tempfile
|
|
21
22
|
import venv
|
|
22
23
|
from typing import Optional, Set, Tuple
|
|
23
24
|
|
|
@@ -25,6 +26,15 @@ from camel.logger import get_logger
|
|
|
25
26
|
|
|
26
27
|
logger = get_logger(__name__)
|
|
27
28
|
|
|
29
|
+
# Pre-compiled regex patterns for command safety checks
|
|
30
|
+
_CMD_PATTERN = re.compile(
|
|
31
|
+
r'(?:^|;|\||&&)\s*\b([a-zA-Z_/][\w\-/]*)', re.IGNORECASE
|
|
32
|
+
)
|
|
33
|
+
_QUOTED_STRING_PATTERN = re.compile(r'''["'][^"']*["']''')
|
|
34
|
+
# Match cd command with optional quoted or unquoted path
|
|
35
|
+
# Handles: cd path, cd "path with spaces", cd 'path with spaces'
|
|
36
|
+
_CD_PATTERN = re.compile(r'\bcd\s+(["\'][^"\']*["\']|[^\s;|&]+)')
|
|
37
|
+
|
|
28
38
|
|
|
29
39
|
def check_command_safety(
|
|
30
40
|
command: str,
|
|
@@ -97,13 +107,12 @@ def check_command_safety(
|
|
|
97
107
|
]
|
|
98
108
|
|
|
99
109
|
# Remove quoted strings to avoid false positives
|
|
100
|
-
clean_command =
|
|
110
|
+
clean_command = _QUOTED_STRING_PATTERN.sub(' ', command)
|
|
101
111
|
|
|
102
112
|
# If whitelist mode, check ALL commands against the whitelist
|
|
103
113
|
if allowed_commands is not None:
|
|
104
114
|
# Extract all command words (at start or after operators)
|
|
105
|
-
|
|
106
|
-
found_commands = re.findall(cmd_pattern, clean_command, re.IGNORECASE)
|
|
115
|
+
found_commands = _CMD_PATTERN.findall(clean_command)
|
|
107
116
|
for cmd in found_commands:
|
|
108
117
|
if cmd.lower() not in allowed_commands:
|
|
109
118
|
return (
|
|
@@ -148,16 +157,28 @@ def sanitize_command(
|
|
|
148
157
|
if not is_safe:
|
|
149
158
|
return False, reason
|
|
150
159
|
|
|
151
|
-
# Additional check for
|
|
160
|
+
# Additional check for local backend: prevent cd outside working directory
|
|
152
161
|
if not use_docker_backend and working_dir and 'cd ' in command:
|
|
153
162
|
# Extract cd commands and check their targets
|
|
154
|
-
|
|
155
|
-
|
|
163
|
+
# Normalize working_dir to ensure consistent comparison
|
|
164
|
+
normalized_working_dir = os.path.normpath(os.path.abspath(working_dir))
|
|
165
|
+
for match in _CD_PATTERN.finditer(command):
|
|
156
166
|
target_path = match.group(1).strip('\'"')
|
|
157
|
-
target_dir = os.path.
|
|
158
|
-
os.path.join(working_dir, target_path)
|
|
167
|
+
target_dir = os.path.normpath(
|
|
168
|
+
os.path.abspath(os.path.join(working_dir, target_path))
|
|
159
169
|
)
|
|
160
|
-
|
|
170
|
+
# Use os.path.commonpath for safe path comparison
|
|
171
|
+
try:
|
|
172
|
+
common = os.path.commonpath(
|
|
173
|
+
[normalized_working_dir, target_dir]
|
|
174
|
+
)
|
|
175
|
+
if common != normalized_working_dir:
|
|
176
|
+
return (
|
|
177
|
+
False,
|
|
178
|
+
"Cannot 'cd' outside of the working directory.",
|
|
179
|
+
)
|
|
180
|
+
except ValueError:
|
|
181
|
+
# Different drives on Windows or other path issues
|
|
161
182
|
return False, "Cannot 'cd' outside of the working directory."
|
|
162
183
|
|
|
163
184
|
return True, command
|
|
@@ -198,7 +219,10 @@ def ensure_uv_available(update_callback=None) -> Tuple[bool, Optional[str]]:
|
|
|
198
219
|
os_type = platform.system()
|
|
199
220
|
|
|
200
221
|
# Install uv using the official installer script
|
|
201
|
-
if os_type in [
|
|
222
|
+
if os_type.lower() in [
|
|
223
|
+
'darwin',
|
|
224
|
+
'linux',
|
|
225
|
+
] or os_type.lower().startswith('linux'):
|
|
202
226
|
# Use curl to download and execute the installer
|
|
203
227
|
install_cmd = "curl -LsSf https://astral.sh/uv/install.sh | sh"
|
|
204
228
|
result = subprocess.run(
|
|
@@ -226,7 +250,7 @@ def ensure_uv_available(update_callback=None) -> Tuple[bool, Optional[str]]:
|
|
|
226
250
|
)
|
|
227
251
|
return True, uv_executable
|
|
228
252
|
|
|
229
|
-
elif os_type == '
|
|
253
|
+
elif os_type.lower() == 'windows':
|
|
230
254
|
# Use PowerShell to install uv on Windows
|
|
231
255
|
install_cmd = (
|
|
232
256
|
"powershell -ExecutionPolicy Bypass -c "
|
|
@@ -293,8 +317,6 @@ def setup_initial_env_with_uv(
|
|
|
293
317
|
"pip",
|
|
294
318
|
"setuptools",
|
|
295
319
|
"wheel",
|
|
296
|
-
"pyautogui",
|
|
297
|
-
"plotly",
|
|
298
320
|
]
|
|
299
321
|
subprocess.run(
|
|
300
322
|
[
|
|
@@ -335,9 +357,22 @@ def setup_initial_env_with_venv(
|
|
|
335
357
|
r"""Set up initial environment using standard venv."""
|
|
336
358
|
try:
|
|
337
359
|
# Create virtual environment with system Python
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
|
|
360
|
+
try:
|
|
361
|
+
venv.create(
|
|
362
|
+
env_path,
|
|
363
|
+
with_pip=True,
|
|
364
|
+
system_site_packages=False,
|
|
365
|
+
symlinks=True,
|
|
366
|
+
)
|
|
367
|
+
except Exception:
|
|
368
|
+
# Fallback to symlinks=False if symlinks=True fails
|
|
369
|
+
# (e.g., on some Windows configurations)
|
|
370
|
+
venv.create(
|
|
371
|
+
env_path,
|
|
372
|
+
with_pip=True,
|
|
373
|
+
system_site_packages=False,
|
|
374
|
+
symlinks=False,
|
|
375
|
+
)
|
|
341
376
|
|
|
342
377
|
# Get pip path
|
|
343
378
|
if platform.system() == 'Windows':
|
|
@@ -350,8 +385,6 @@ def setup_initial_env_with_venv(
|
|
|
350
385
|
"pip",
|
|
351
386
|
"setuptools",
|
|
352
387
|
"wheel",
|
|
353
|
-
"pyautogui",
|
|
354
|
-
"plotly",
|
|
355
388
|
]
|
|
356
389
|
subprocess.run(
|
|
357
390
|
[pip_path, "install", "--upgrade", *essential_packages],
|
|
@@ -382,7 +415,20 @@ def setup_initial_env_with_venv(
|
|
|
382
415
|
def clone_current_environment(
|
|
383
416
|
env_path: str, working_dir: str, update_callback=None
|
|
384
417
|
) -> bool:
|
|
385
|
-
r"""
|
|
418
|
+
r"""Clone the current Python environment to a new virtual environment.
|
|
419
|
+
|
|
420
|
+
This function creates a new virtual environment with the same Python
|
|
421
|
+
version as the current environment and installs all packages from
|
|
422
|
+
the current environment.
|
|
423
|
+
|
|
424
|
+
Args:
|
|
425
|
+
env_path: Path where the new environment will be created.
|
|
426
|
+
working_dir: Working directory for subprocess commands.
|
|
427
|
+
update_callback: Optional callback for status updates.
|
|
428
|
+
|
|
429
|
+
Returns:
|
|
430
|
+
True if the environment was created successfully, False otherwise.
|
|
431
|
+
"""
|
|
386
432
|
try:
|
|
387
433
|
if os.path.exists(env_path):
|
|
388
434
|
if update_callback:
|
|
@@ -391,17 +437,37 @@ def clone_current_environment(
|
|
|
391
437
|
|
|
392
438
|
if update_callback:
|
|
393
439
|
update_callback(
|
|
394
|
-
f"
|
|
440
|
+
f"Cloning current Python environment to: {env_path}\n"
|
|
395
441
|
)
|
|
396
442
|
|
|
443
|
+
# Get current Python version
|
|
444
|
+
current_version = f"{sys.version_info.major}.{sys.version_info.minor}"
|
|
445
|
+
|
|
446
|
+
# Get list of installed packages in current environment
|
|
447
|
+
if update_callback:
|
|
448
|
+
update_callback("Collecting installed packages...\n")
|
|
449
|
+
|
|
450
|
+
freeze_result = subprocess.run(
|
|
451
|
+
[sys.executable, "-m", "pip", "freeze"],
|
|
452
|
+
capture_output=True,
|
|
453
|
+
text=True,
|
|
454
|
+
timeout=60,
|
|
455
|
+
)
|
|
456
|
+
if freeze_result.returncode != 0:
|
|
457
|
+
if update_callback:
|
|
458
|
+
update_callback(
|
|
459
|
+
"Warning: Failed to get installed packages, "
|
|
460
|
+
"creating empty environment\n"
|
|
461
|
+
)
|
|
462
|
+
installed_packages = ""
|
|
463
|
+
else:
|
|
464
|
+
installed_packages = freeze_result.stdout.strip()
|
|
465
|
+
|
|
397
466
|
# Try to use uv if available
|
|
398
467
|
success, uv_path = ensure_uv_available(update_callback)
|
|
399
|
-
if success and uv_path:
|
|
400
|
-
# Get current Python version
|
|
401
|
-
current_version = (
|
|
402
|
-
f"{sys.version_info.major}.{sys.version_info.minor}"
|
|
403
|
-
)
|
|
404
468
|
|
|
469
|
+
if success and uv_path:
|
|
470
|
+
# Create venv with uv
|
|
405
471
|
subprocess.run(
|
|
406
472
|
[uv_path, "venv", "--python", current_version, env_path],
|
|
407
473
|
check=True,
|
|
@@ -416,7 +482,7 @@ def clone_current_environment(
|
|
|
416
482
|
else:
|
|
417
483
|
python_path = os.path.join(env_path, "bin", "python")
|
|
418
484
|
|
|
419
|
-
# Install pip
|
|
485
|
+
# Install pip, setuptools, wheel first
|
|
420
486
|
subprocess.run(
|
|
421
487
|
[
|
|
422
488
|
uv_path,
|
|
@@ -434,10 +500,38 @@ def clone_current_environment(
|
|
|
434
500
|
timeout=300,
|
|
435
501
|
)
|
|
436
502
|
|
|
437
|
-
if
|
|
438
|
-
|
|
439
|
-
|
|
503
|
+
# Install cloned packages if any
|
|
504
|
+
if installed_packages:
|
|
505
|
+
if update_callback:
|
|
506
|
+
update_callback("Installing cloned packages with uv...\n")
|
|
507
|
+
# Write requirements to temp file (auto-deleted)
|
|
508
|
+
fd, requirements_file = tempfile.mkstemp(
|
|
509
|
+
suffix=".txt", prefix="requirements_", dir=working_dir
|
|
440
510
|
)
|
|
511
|
+
try:
|
|
512
|
+
with os.fdopen(fd, "w") as f:
|
|
513
|
+
f.write(installed_packages)
|
|
514
|
+
subprocess.run(
|
|
515
|
+
[
|
|
516
|
+
uv_path,
|
|
517
|
+
"pip",
|
|
518
|
+
"install",
|
|
519
|
+
"--python",
|
|
520
|
+
python_path,
|
|
521
|
+
"-r",
|
|
522
|
+
requirements_file,
|
|
523
|
+
],
|
|
524
|
+
check=True,
|
|
525
|
+
capture_output=True,
|
|
526
|
+
cwd=working_dir,
|
|
527
|
+
timeout=600,
|
|
528
|
+
)
|
|
529
|
+
finally:
|
|
530
|
+
if os.path.exists(requirements_file):
|
|
531
|
+
os.remove(requirements_file)
|
|
532
|
+
|
|
533
|
+
if update_callback:
|
|
534
|
+
update_callback("[UV] Environment cloned successfully!\n")
|
|
441
535
|
return True
|
|
442
536
|
else:
|
|
443
537
|
# Fallback to standard venv
|
|
@@ -445,49 +539,82 @@ def clone_current_environment(
|
|
|
445
539
|
update_callback(
|
|
446
540
|
"Falling back to standard venv for cloning environment\n"
|
|
447
541
|
)
|
|
542
|
+
try:
|
|
543
|
+
venv.create(env_path, with_pip=True, symlinks=True)
|
|
544
|
+
except Exception:
|
|
545
|
+
# Fallback to symlinks=False if symlinks=True fails
|
|
546
|
+
venv.create(env_path, with_pip=True, symlinks=False)
|
|
448
547
|
|
|
449
|
-
|
|
450
|
-
|
|
451
|
-
# Ensure pip is properly available
|
|
548
|
+
# Get python/pip path
|
|
452
549
|
if platform.system() == 'Windows':
|
|
453
550
|
python_path = os.path.join(env_path, "Scripts", "python.exe")
|
|
454
551
|
else:
|
|
455
552
|
python_path = os.path.join(env_path, "bin", "python")
|
|
456
553
|
|
|
457
|
-
if os.path.exists(python_path):
|
|
458
|
-
subprocess.run(
|
|
459
|
-
[python_path, "-m", "pip", "install", "--upgrade", "pip"],
|
|
460
|
-
check=True,
|
|
461
|
-
capture_output=True,
|
|
462
|
-
cwd=working_dir,
|
|
463
|
-
timeout=60,
|
|
464
|
-
)
|
|
554
|
+
if not os.path.exists(python_path):
|
|
465
555
|
if update_callback:
|
|
466
556
|
update_callback(
|
|
467
|
-
"
|
|
557
|
+
f"Warning: Python executable not found at "
|
|
558
|
+
f"{python_path}\n"
|
|
468
559
|
)
|
|
469
|
-
|
|
560
|
+
return False
|
|
561
|
+
|
|
562
|
+
# Upgrade pip
|
|
563
|
+
subprocess.run(
|
|
564
|
+
[python_path, "-m", "pip", "install", "--upgrade", "pip"],
|
|
565
|
+
check=True,
|
|
566
|
+
capture_output=True,
|
|
567
|
+
cwd=working_dir,
|
|
568
|
+
timeout=60,
|
|
569
|
+
)
|
|
570
|
+
|
|
571
|
+
# Install cloned packages if any
|
|
572
|
+
if installed_packages:
|
|
470
573
|
if update_callback:
|
|
471
|
-
update_callback(
|
|
472
|
-
|
|
473
|
-
|
|
574
|
+
update_callback("Installing cloned packages with pip...\n")
|
|
575
|
+
# Write requirements to temp file (auto-deleted)
|
|
576
|
+
fd, requirements_file = tempfile.mkstemp(
|
|
577
|
+
suffix=".txt", prefix="requirements_", dir=working_dir
|
|
578
|
+
)
|
|
579
|
+
try:
|
|
580
|
+
with os.fdopen(fd, "w") as f:
|
|
581
|
+
f.write(installed_packages)
|
|
582
|
+
subprocess.run(
|
|
583
|
+
[
|
|
584
|
+
python_path,
|
|
585
|
+
"-m",
|
|
586
|
+
"pip",
|
|
587
|
+
"install",
|
|
588
|
+
"-r",
|
|
589
|
+
requirements_file,
|
|
590
|
+
],
|
|
591
|
+
check=True,
|
|
592
|
+
capture_output=True,
|
|
593
|
+
cwd=working_dir,
|
|
594
|
+
timeout=600,
|
|
474
595
|
)
|
|
596
|
+
finally:
|
|
597
|
+
if os.path.exists(requirements_file):
|
|
598
|
+
os.remove(requirements_file)
|
|
599
|
+
|
|
600
|
+
if update_callback:
|
|
601
|
+
update_callback("Environment cloned successfully!\n")
|
|
475
602
|
return True
|
|
476
603
|
|
|
477
604
|
except subprocess.CalledProcessError as e:
|
|
478
605
|
error_msg = e.stderr.decode() if e.stderr else str(e)
|
|
479
606
|
if update_callback:
|
|
480
|
-
update_callback(f"Failed to
|
|
481
|
-
logger.error(f"Failed to
|
|
607
|
+
update_callback(f"Failed to clone environment: {error_msg}\n")
|
|
608
|
+
logger.error(f"Failed to clone environment: {error_msg}")
|
|
482
609
|
return False
|
|
483
610
|
except subprocess.TimeoutExpired:
|
|
484
611
|
if update_callback:
|
|
485
|
-
update_callback("Environment
|
|
612
|
+
update_callback("Environment cloning timed out\n")
|
|
486
613
|
return False
|
|
487
614
|
except Exception as e:
|
|
488
615
|
if update_callback:
|
|
489
|
-
update_callback(f"Failed to
|
|
490
|
-
logger.error(f"Failed to
|
|
616
|
+
update_callback(f"Failed to clone environment: {e!s}\n")
|
|
617
|
+
logger.error(f"Failed to clone environment: {e}")
|
|
491
618
|
return False
|
|
492
619
|
|
|
493
620
|
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# ========= Copyright 2023-
|
|
1
|
+
# ========= Copyright 2023-2026 @ CAMEL-AI.org. All Rights Reserved. =========
|
|
2
2
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
|
3
3
|
# you may not use this file except in compliance with the License.
|
|
4
4
|
# You may obtain a copy of the License at
|
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
11
11
|
# See the License for the specific language governing permissions and
|
|
12
12
|
# limitations under the License.
|
|
13
|
-
# ========= Copyright 2023-
|
|
13
|
+
# ========= Copyright 2023-2026 @ CAMEL-AI.org. All Rights Reserved. =========
|
|
14
14
|
|
|
15
15
|
from typing import List, Optional
|
|
16
16
|
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# ========= Copyright 2023-
|
|
1
|
+
# ========= Copyright 2023-2026 @ CAMEL-AI.org. All Rights Reserved. =========
|
|
2
2
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
|
3
3
|
# you may not use this file except in compliance with the License.
|
|
4
4
|
# You may obtain a copy of the License at
|
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
11
11
|
# See the License for the specific language governing permissions and
|
|
12
12
|
# limitations under the License.
|
|
13
|
-
# ========= Copyright 2023-
|
|
13
|
+
# ========= Copyright 2023-2026 @ CAMEL-AI.org. All Rights Reserved. =========
|
|
14
14
|
import datetime
|
|
15
15
|
import os
|
|
16
16
|
from http import HTTPStatus
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# ========= Copyright 2023-
|
|
1
|
+
# ========= Copyright 2023-2026 @ CAMEL-AI.org. All Rights Reserved. =========
|
|
2
2
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
|
3
3
|
# you may not use this file except in compliance with the License.
|
|
4
4
|
# You may obtain a copy of the License at
|
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
11
11
|
# See the License for the specific language governing permissions and
|
|
12
12
|
# limitations under the License.
|
|
13
|
-
# ========= Copyright 2023-
|
|
13
|
+
# ========= Copyright 2023-2026 @ CAMEL-AI.org. All Rights Reserved. =========
|
|
14
14
|
|
|
15
15
|
import asyncio
|
|
16
16
|
import base64
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# ========= Copyright 2023-
|
|
1
|
+
# ========= Copyright 2023-2026 @ CAMEL-AI.org. All Rights Reserved. =========
|
|
2
2
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
|
3
3
|
# you may not use this file except in compliance with the License.
|
|
4
4
|
# You may obtain a copy of the License at
|
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
11
11
|
# See the License for the specific language governing permissions and
|
|
12
12
|
# limitations under the License.
|
|
13
|
-
# ========= Copyright 2023-
|
|
13
|
+
# ========= Copyright 2023-2026 @ CAMEL-AI.org. All Rights Reserved. =========
|
|
14
14
|
|
|
15
15
|
# Enables postponed evaluation of annotations (for string-based type hints)
|
|
16
16
|
from __future__ import annotations
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# ========= Copyright 2023-
|
|
1
|
+
# ========= Copyright 2023-2026 @ CAMEL-AI.org. All Rights Reserved. =========
|
|
2
2
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
|
3
3
|
# you may not use this file except in compliance with the License.
|
|
4
4
|
# You may obtain a copy of the License at
|
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
11
11
|
# See the License for the specific language governing permissions and
|
|
12
12
|
# limitations under the License.
|
|
13
|
-
# ========= Copyright 2023-
|
|
13
|
+
# ========= Copyright 2023-2026 @ CAMEL-AI.org. All Rights Reserved. =========
|
|
14
14
|
|
|
15
15
|
# Enables postponed evaluation of annotations (for string-based type hints)
|
|
16
16
|
from __future__ import annotations
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# ========= Copyright 2023-
|
|
1
|
+
# ========= Copyright 2023-2026 @ CAMEL-AI.org. All Rights Reserved. =========
|
|
2
2
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
|
3
3
|
# you may not use this file except in compliance with the License.
|
|
4
4
|
# You may obtain a copy of the License at
|
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
11
11
|
# See the License for the specific language governing permissions and
|
|
12
12
|
# limitations under the License.
|
|
13
|
-
# ========= Copyright 2023-
|
|
13
|
+
# ========= Copyright 2023-2026 @ CAMEL-AI.org. All Rights Reserved. =========
|
|
14
14
|
import os
|
|
15
15
|
from typing import List, Literal, Optional
|
|
16
16
|
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# ========= Copyright 2023-
|
|
1
|
+
# ========= Copyright 2023-2026 @ CAMEL-AI.org. All Rights Reserved. =========
|
|
2
2
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
|
3
3
|
# you may not use this file except in compliance with the License.
|
|
4
4
|
# You may obtain a copy of the License at
|
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
11
11
|
# See the License for the specific language governing permissions and
|
|
12
12
|
# limitations under the License.
|
|
13
|
-
# ========= Copyright 2023-
|
|
13
|
+
# ========= Copyright 2023-2026 @ CAMEL-AI.org. All Rights Reserved. =========
|
|
14
14
|
|
|
15
15
|
from __future__ import annotations
|
|
16
16
|
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# ========= Copyright 2023-
|
|
1
|
+
# ========= Copyright 2023-2026 @ CAMEL-AI.org. All Rights Reserved. =========
|
|
2
2
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
|
3
3
|
# you may not use this file except in compliance with the License.
|
|
4
4
|
# You may obtain a copy of the License at
|
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
11
11
|
# See the License for the specific language governing permissions and
|
|
12
12
|
# limitations under the License.
|
|
13
|
-
# ========= Copyright 2023-
|
|
13
|
+
# ========= Copyright 2023-2026 @ CAMEL-AI.org. All Rights Reserved. =========
|
|
14
14
|
|
|
15
15
|
import os
|
|
16
16
|
import time
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# ========= Copyright 2023-
|
|
1
|
+
# ========= Copyright 2023-2026 @ CAMEL-AI.org. All Rights Reserved. =========
|
|
2
2
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
|
3
3
|
# you may not use this file except in compliance with the License.
|
|
4
4
|
# You may obtain a copy of the License at
|
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
11
11
|
# See the License for the specific language governing permissions and
|
|
12
12
|
# limitations under the License.
|
|
13
|
-
# ========= Copyright 2023-
|
|
13
|
+
# ========= Copyright 2023-2026 @ CAMEL-AI.org. All Rights Reserved. =========
|
|
14
14
|
|
|
15
15
|
import os
|
|
16
16
|
from typing import Any, Dict, List, Optional, Union
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# ========= Copyright 2023-
|
|
1
|
+
# ========= Copyright 2023-2026 @ CAMEL-AI.org. All Rights Reserved. =========
|
|
2
2
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
|
3
3
|
# you may not use this file except in compliance with the License.
|
|
4
4
|
# You may obtain a copy of the License at
|
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
11
11
|
# See the License for the specific language governing permissions and
|
|
12
12
|
# limitations under the License.
|
|
13
|
-
# ========= Copyright 2023-
|
|
13
|
+
# ========= Copyright 2023-2026 @ CAMEL-AI.org. All Rights Reserved. =========
|
|
14
14
|
import os
|
|
15
15
|
import xml.etree.ElementTree as ET
|
|
16
16
|
from typing import Any, Dict, List
|
camel/toolkits/zapier_toolkit.py
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# ========= Copyright 2023-
|
|
1
|
+
# ========= Copyright 2023-2026 @ CAMEL-AI.org. All Rights Reserved. =========
|
|
2
2
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
|
3
3
|
# you may not use this file except in compliance with the License.
|
|
4
4
|
# You may obtain a copy of the License at
|
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
11
11
|
# See the License for the specific language governing permissions and
|
|
12
12
|
# limitations under the License.
|
|
13
|
-
# ========= Copyright 2023-
|
|
13
|
+
# ========= Copyright 2023-2026 @ CAMEL-AI.org. All Rights Reserved. =========
|
|
14
14
|
|
|
15
15
|
import os
|
|
16
16
|
from typing import Any, Dict, List, Optional
|
camel/types/__init__.py
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# ========= Copyright 2023-
|
|
1
|
+
# ========= Copyright 2023-2026 @ CAMEL-AI.org. All Rights Reserved. =========
|
|
2
2
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
|
3
3
|
# you may not use this file except in compliance with the License.
|
|
4
4
|
# You may obtain a copy of the License at
|
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
11
11
|
# See the License for the specific language governing permissions and
|
|
12
12
|
# limitations under the License.
|
|
13
|
-
# ========= Copyright 2023-
|
|
13
|
+
# ========= Copyright 2023-2026 @ CAMEL-AI.org. All Rights Reserved. =========
|
|
14
14
|
from .enums import (
|
|
15
15
|
AudioModelType,
|
|
16
16
|
EmbeddingModelType,
|
camel/types/agents/__init__.py
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# ========= Copyright 2023-
|
|
1
|
+
# ========= Copyright 2023-2026 @ CAMEL-AI.org. All Rights Reserved. =========
|
|
2
2
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
|
3
3
|
# you may not use this file except in compliance with the License.
|
|
4
4
|
# You may obtain a copy of the License at
|
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
11
11
|
# See the License for the specific language governing permissions and
|
|
12
12
|
# limitations under the License.
|
|
13
|
-
# ========= Copyright 2023-
|
|
13
|
+
# ========= Copyright 2023-2026 @ CAMEL-AI.org. All Rights Reserved. =========
|
|
14
14
|
from .tool_calling_record import ToolCallingRecord
|
|
15
15
|
|
|
16
16
|
__all__ = ["ToolCallingRecord"]
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# ========= Copyright 2023-
|
|
1
|
+
# ========= Copyright 2023-2026 @ CAMEL-AI.org. All Rights Reserved. =========
|
|
2
2
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
|
3
3
|
# you may not use this file except in compliance with the License.
|
|
4
4
|
# You may obtain a copy of the License at
|
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
11
11
|
# See the License for the specific language governing permissions and
|
|
12
12
|
# limitations under the License.
|
|
13
|
-
# ========= Copyright 2023-
|
|
13
|
+
# ========= Copyright 2023-2026 @ CAMEL-AI.org. All Rights Reserved. =========
|
|
14
14
|
from typing import Any, Dict, List, Optional
|
|
15
15
|
|
|
16
16
|
from pydantic import BaseModel
|
camel/types/enums.py
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# ========= Copyright 2023-
|
|
1
|
+
# ========= Copyright 2023-2026 @ CAMEL-AI.org. All Rights Reserved. =========
|
|
2
2
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
|
3
3
|
# you may not use this file except in compliance with the License.
|
|
4
4
|
# You may obtain a copy of the License at
|
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
11
11
|
# See the License for the specific language governing permissions and
|
|
12
12
|
# limitations under the License.
|
|
13
|
-
# ========= Copyright 2023-
|
|
13
|
+
# ========= Copyright 2023-2026 @ CAMEL-AI.org. All Rights Reserved. =========
|
|
14
14
|
import os
|
|
15
15
|
from enum import Enum, EnumMeta
|
|
16
16
|
from typing import Union, cast
|
|
@@ -1329,8 +1329,6 @@ class ModelType(UnifiedModelType, Enum):
|
|
|
1329
1329
|
ModelType.CEREBRAS_GPT_OSS_120B,
|
|
1330
1330
|
ModelType.CEREBRAS_LLAMA_3_3_70B,
|
|
1331
1331
|
ModelType.CEREBRAS_QWEN_3_32B,
|
|
1332
|
-
ModelType.DEEPSEEK_CHAT,
|
|
1333
|
-
ModelType.DEEPSEEK_REASONER,
|
|
1334
1332
|
ModelType.PPIO_DEEPSEEK_R1_TURBO,
|
|
1335
1333
|
ModelType.PPIO_DEEPSEEK_V3_TURBO,
|
|
1336
1334
|
ModelType.PPIO_DEEPSEEK_R1_COMMUNITY,
|
|
@@ -1373,6 +1371,8 @@ class ModelType(UnifiedModelType, Enum):
|
|
|
1373
1371
|
}:
|
|
1374
1372
|
return 100_000
|
|
1375
1373
|
elif self in {
|
|
1374
|
+
ModelType.DEEPSEEK_CHAT,
|
|
1375
|
+
ModelType.DEEPSEEK_REASONER,
|
|
1376
1376
|
ModelType.GPT_4O,
|
|
1377
1377
|
ModelType.GPT_4O_MINI,
|
|
1378
1378
|
ModelType.GPT_4_TURBO,
|
|
@@ -1827,6 +1827,7 @@ class ModelPlatformType(Enum):
|
|
|
1827
1827
|
AIHUBMIX = "aihubmix"
|
|
1828
1828
|
MINIMAX = "minimax"
|
|
1829
1829
|
CEREBRAS = "cerebras"
|
|
1830
|
+
FUNCTION_GEMMA = "function-gemma"
|
|
1830
1831
|
|
|
1831
1832
|
@classmethod
|
|
1832
1833
|
def from_name(cls, name):
|
camel/types/mcp_registries.py
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# ========= Copyright 2023-
|
|
1
|
+
# ========= Copyright 2023-2026 @ CAMEL-AI.org. All Rights Reserved. =========
|
|
2
2
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
|
3
3
|
# you may not use this file except in compliance with the License.
|
|
4
4
|
# You may obtain a copy of the License at
|
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
11
11
|
# See the License for the specific language governing permissions and
|
|
12
12
|
# limitations under the License.
|
|
13
|
-
# ========= Copyright 2023-
|
|
13
|
+
# ========= Copyright 2023-2026 @ CAMEL-AI.org. All Rights Reserved. =========
|
|
14
14
|
import os
|
|
15
15
|
import platform
|
|
16
16
|
from enum import Enum, auto
|
camel/types/openai_types.py
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# ========= Copyright 2023-
|
|
1
|
+
# ========= Copyright 2023-2026 @ CAMEL-AI.org. All Rights Reserved. =========
|
|
2
2
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
|
3
3
|
# you may not use this file except in compliance with the License.
|
|
4
4
|
# You may obtain a copy of the License at
|
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
11
11
|
# See the License for the specific language governing permissions and
|
|
12
12
|
# limitations under the License.
|
|
13
|
-
# ========= Copyright 2023-
|
|
13
|
+
# ========= Copyright 2023-2026 @ CAMEL-AI.org. All Rights Reserved. =========
|
|
14
14
|
# isort: skip_file
|
|
15
15
|
from openai.types.chat.chat_completion import ChatCompletion, Choice
|
|
16
16
|
from openai.types.chat.chat_completion_assistant_message_param import (
|