{"id":27826,"library":"ghostos","title":"GhostOS","description":"GhostOS is a framework that simulates an operating system with a Python Code Interface for AI agents. It provides tools for agent reasoning, prompt management, and integration with various LLM services (OpenAI, DeepSeek, SiliconFlow, Aliyun). The current version is 0.3.0 (latest stable), with a development branch 0.4.0-dev1. Release cadence is irregular, with frequent minor patches.","status":"active","version":"0.3.0","language":"python","source_language":"en","source_url":"https://github.com/ghost-in-moss/GhostOS","tags":["ai-agents","llm","framework","python","operating-system-simulator"],"install":[{"cmd":"pip install ghostos","lang":"bash","label":"Base install"},{"cmd":"pip install ghostos[realtime]","lang":"bash","label":"With realtime audio support"}],"dependencies":[{"reason":"LLM API client for OpenAI-compatible services","package":"openai","optional":false},{"reason":"Data validation and settings management","package":"pydantic","optional":false},{"reason":"Audio I/O for realtime features","package":"pyaudio","optional":true},{"reason":"Web UI for GhostOS chat","package":"streamlit","optional":true}],"imports":[{"note":"MossAgent was deprecated in v0.4.0-dev1 in favor of MossGhost; but in v0.3.0 it is still the correct import path.","wrong":"from ghostos import MossAgent","symbol":"MossAgent","correct":"from ghostos.agents import MossAgent"},{"note":"MossGhost is new in v0.4.0-dev1; in v0.3.0 it does not exist.","wrong":"from ghostos.moss import MossGhost","symbol":"MossGhost","correct":"from ghostos.agents import MossGhost"}],"quickstart":{"code":"import os\nfrom ghostos.agents import MossAgent\nfrom ghostos.core import AgentConfig\n\n# Ensure API key is set\napi_key = os.environ.get('OPENAI_API_KEY', '')\nif not api_key:\n    raise ValueError('OPENAI_API_KEY not set')\n\nagent = MossAgent(\n    config=AgentConfig(\n        model='gpt-4',\n        api_key=api_key\n    )\n)\nresponse = agent.run('Hello, GhostOS!')\nprint(response)","lang":"python","description":"Minimal example: create a MossAgent and run a prompt."},"warnings":[{"fix":"Replace import: from ghostos.agents import MossGhost and use MossGhost class.","message":"MossAgent is deprecated in v0.4.0-dev1; use MossGhost instead.","severity":"breaking","affected_versions":">=0.4.0-dev1"},{"fix":"Watch for changes in v0.4.0+ and migrate to the new prompt model.","message":"Importing from 'ghostos.prompter' module is being refactored; the PromptObjectModel API may change.","severity":"deprecated","affected_versions":"all"},{"fix":"Set OPENAI_PROXY to an empty string or a valid proxy URL.","message":"OpenAI realtime feature requires both 'OPENAI_API_KEY' and 'OPENAI_PROXY' env vars; empty proxy may cause errors.","severity":"gotcha","affected_versions":"<=0.1.8"},{"fix":"Upgrade to 0.1.4+ or manually patch imports to use typing_extensions.","message":"Python 3.10 compatibility: some imports from 'typing' instead of 'typing_extensions' cause ImportError.","severity":"bug","affected_versions":"<=0.1.3"}],"env_vars":null,"last_verified":"2026-05-09T00:00:00.000Z","next_check":"2026-08-07T00:00:00.000Z","problems":[{"fix":"Use: from ghostos.agents import MossAgent","cause":"Importing directly from 'ghostos' instead of submodule 'ghostos.agents'.","error":"AttributeError: module 'ghostos' has no attribute 'MossAgent'"},{"fix":"Check model name: use 'gpt-4' or 'gpt-3.5-turbo' that your API key has access to.","cause":"Model name is incorrect or API key lacks access.","error":"openai.NotFoundError: Error code: 404 - {'error': {'message': 'The model `gpt-4` does not exist or you do not have access to it.'}}"},{"fix":"Set env var: export OPENAI_PROXY='' (empty string) or a valid proxy.","cause":"Realtime feature requires OPENAI_PROXY even if empty.","error":"ValueError: Cannot connect to realtime API: Missing OPENAI_PROXY environment variable"}],"ecosystem":"pypi","meta_description":null,"install_score":null,"install_tag":null,"quickstart_score":null,"quickstart_tag":null}