full-stack.mdx 1.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081
  1. ---
  2. title: '💻 Full stack'
  3. ---
  4. Get started with full-stack RAG applications using Embedchain's easy-to-use CLI tool. Set up everything with just a few commands, whether you prefer Docker or not.
  5. ## Prerequisites
  6. Choose your setup method:
  7. * [Without docker](#without-docker)
  8. * [With Docker](#with-docker)
  9. ### Without Docker
  10. Ensure these are installed:
  11. - Embedchain python package (`pip install embedchain`)
  12. - [Node.js](https://docs.npmjs.com/downloading-and-installing-node-js-and-npm) and [Yarn](https://classic.yarnpkg.com/lang/en/docs/install/)
  13. ### With Docker
  14. Install Docker from [Docker's official website](https://docs.docker.com/engine/install/).
  15. ## Quick Start Guide
  16. ### Install the package
  17. Before proceeding, make sure you have the Embedchain package installed.
  18. ```bash
  19. pip install embedchain -U
  20. ```
  21. ### Setting Up
  22. For the purpose of the demo, you have to set `OPENAI_API_KEY` to start with but you can choose any llm by changing the configuration easily.
  23. ### Installation Commands
  24. <CodeGroup>
  25. ```bash without docker
  26. ec create-app my-app
  27. cd my-app
  28. ec start
  29. ```
  30. ```bash with docker
  31. ec create-app my-app --docker
  32. cd my-app
  33. ec start --docker
  34. ```
  35. </CodeGroup>
  36. ### What Happens Next?
  37. 1. Embedchain fetches a full stack template (FastAPI backend, Next.JS frontend).
  38. 2. Installs required components.
  39. 3. Launches both frontend and backend servers.
  40. ### See It In Action
  41. Open http://localhost:3000 to view the chat UI.
  42. ![full stack example](/images/fullstack.png)
  43. ### Admin Panel
  44. Check out the Embedchain admin panel to see the document chunks for your RAG application.
  45. ![full stack chunks](/images/fullstack-chunks.png)
  46. ### API Server
  47. If you want to access the API server, you can do so at http://localhost:8000/docs.
  48. ![API Server](/images/fullstack-api-server.png)
  49. You can customize the UI and code as per your requirements.