--- title: Volodymyr Zelensky emoji: 🌍 colorFrom: yellow colorTo: blue sdk: gradio sdk_version: 4.36.1 app_file: app.py pinned: false license: mit short_description: A Claude-based bot w/ custom knowledge and instructions thumbnail: >- https://cdn-uploads.huggingface.co/production/uploads/64964a906105da037e718533/rTT1nU9Cx77SWXrWt5OMo.png --- Claude 3.5 Sonnet has been well received by educators interested in AI integration. For many, it is the first model to outperform its OpenAI competitor, GPT-4o, and its "artifact" feature seems particularly successful. However, the inability to create shareable assistants (like custom GPTs) is often pointed out as clear disadvantage. In reality, just like OpenAI, Anthropic has an "API" interface, usually meant for developers, which makes it possible to create chatbots with custom knowledge and instructions. This is what you will find here. --> Duplicate this space to create your own Claude-powered assistant with custom knowledge and instructions. Steps = - Create a HuggingFace account if you do not have one - Set your [Anthropic](https://console.anthropic.com/dashboard) API key as a secret - Set desired username and password as secrets - Upload the desired PDF knowledge base / reference document for the assistant under "Files" - Copy the path where indicated in app.py - Change the custom instructions to fit your use case - Change UI elements as needed Important = - This set-up uses a very simple retrieval strategy. Advanced used should consider using [Voyage AI](https://docs.anthropic.com/en/docs/build-with-claude/embeddings) as recommended by Anthropic - It does not have a vector store, and is thus best for a single, small document (e.g., one-page rubric) - You have the option to use Claude 3.5 Sonnet or the much cheaper Claude 3 Haiku (see pricing [here](https://www.anthropic.com/pricing#anthropic-api)) - Advanced RAG for multiple, longer documents and internet access are projects for another time :)