File: README.md
Llama Tutor
Tech stack
- Llama 3.1 70B from Meta for the LLM
- Together AI for LLM inference
- Next.js app router with Tailwind
- Exa.js for the search API
- Helicone for observability
- Plausible for website analytics
Cloning & running
- Fork or clone the repo
- Create an account at Together AI for the LLM
- Create an account at Exa
- Create an account at Helicone for observability
- Create a
.env(use the.example.envfor reference) and replace the API keys - Run
npm installandnpm run devto install dependencies and run locally
Future Tasks
- Add a share & copy buttons that folks can click on after convos are generated
- Add potential follow up questions + new chat at the end of chat page
- Split the page into two pages and add back the footer
- Move all my icons into their own typescript file (transform.tools)
- Add a more detailed landing page with a nice section with the GitHub link
- Add nice hamburger menu on mobile
- Try out the generative UI stuff from Vercel
- Add a nicer dropdown overall
File: package.json
{
"name": "llama-tutor",
"version": "0.1.0",
"private": true,
"scripts": {
"dev": "next dev",
"build": "next build",
"start": "next start",
"lint": "next lint"
},
"dependencies": {
"@headlessui/react": "^2.1.2",
"@mozilla/readability": "^0.5.0",
"@upstash/ratelimit": "^2.0.7",
"@upstash/redis": "^1.35.7",
"eventsource-parser": "^1.1.2",
"exa-js": "^2.0.11",
"jsdom": "^24.1.0",
"llama3-tokenizer-js": "^1.1.3",
"next": "16.0.10",
"next-plausible": "^3.12.5",
"openai": "^4.52.7",
"react": "^18",
"react-dom": "^18",
"react-hot-toast": "^2.4.1",
"react-markdown": "^9.0.1",
"together-ai": "^0.32.0",
"zod": "^4.1.13"
},
"devDependencies": {
"@tailwindcss/typography": "^0.5.13",
"@types/jsdom": "^21.1.6",
"@types/node": "^20",
"@types/react": "^18",
"@types/react-dom": "^18",
"eslint": "^8",
"eslint-config-next": "16.0.7",
"postcss": "^8",
"prettier": "^3.2.5",
"prettier-plugin-tailwindcss": "^0.6.0",
"tailwindcss": "^3.4.1",
"typescript": "^5"
}
}
File: tsconfig.json
{
"compilerOptions": {
"lib": [
"dom",
"dom.iterable",
"esnext"
],
"allowJs": true,
"skipLibCheck": true,
"strict": true,
"noEmit": true,
"esModuleInterop": true,
"module": "esnext",
"moduleResolution": "bundler",
"resolveJsonModule": true,
"isolatedModules": true,
"jsx": "react-jsx",
"incremental": true,
"plugins": [
{
"name": "next"
}
],
"paths": {
"@/": [
"./"
]
},
"target": "ES2017"
},
"include": [
"next-env.d.ts",
"/*.ts",
"/.tsx",
".next/types/**/.ts",
".next/dev/types/**/*.ts"
],
"exclude": [
"node_modules"
]
}
File: .eslintrc.json
{
"extends": "next/core-web-vitals"
}