-
-
Notifications
You must be signed in to change notification settings - Fork 145
Docs: Improve local setup instructions for API keys & .env file structure #215
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. Weβll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Changes from 2 commits
15465f8
5ad8a6d
092d143
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,10 +1,12 @@ | ||
| user=postgres | ||
| password=[YOUR-PASSWORD] | ||
| host= | ||
| port=5432 | ||
| SUPABASE_URL=[URL] | ||
| SUPABASE_KEY=[URL] | ||
|
|
||
| user=postgres.<project> | ||
| password=[YOUR-PASSWORD] | ||
| host=aws-<location>.pooler.supabase.com | ||
| port=5432 | ||
| dbname=postgres | ||
| GROQ_API_KEY= | ||
| SUPABASE_URL= | ||
| SUPABASE_KEY= | ||
| GEMINI_API_KEY= | ||
| YOUTUBE_API_KEY= | ||
|
|
||
| GROQ_API_KEY=[URL] | ||
|
coderabbitai[bot] marked this conversation as resolved.
Outdated
|
||
|
|
||
| GEMINI_API_KEY=[URL] | ||
|
coderabbitai[bot] marked this conversation as resolved.
Outdated
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -84,15 +84,15 @@ Ensure you have the following installed: | |
| #### 1. Clone the repository | ||
|
|
||
| ```sh | ||
| git clone https://github.com/AOSSIE-Org/InPact.git | ||
| cd inpact | ||
| git clone https://github.com/AOSSIE-Org/InPactAI.git | ||
| cd InPactAI | ||
| ``` | ||
|
|
||
| #### 2. Frontend Setup | ||
|
|
||
| 1. Navigate to the frontend directory: | ||
| ```sh | ||
| cd frontend | ||
| cd Frontend | ||
| ``` | ||
|
|
||
| 2. Install dependencies: | ||
|
|
@@ -116,23 +116,34 @@ npm install | |
|
|
||
| 1. Navigate to the backend directory: | ||
| ```sh | ||
| cd ../backend | ||
| cd Backend | ||
| ``` | ||
|
|
||
| 2. Install dependencies: | ||
| 2. Create a virtual environment | ||
| ```sh | ||
| pip install -r requirements.txt | ||
| python -m venv venv | ||
| ``` | ||
|
|
||
| 3. Activate the virtual environment | ||
| ```sh | ||
| venv\Scripts\activate | ||
| ``` | ||
|
Comment on lines
+127
to
+130
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Add cross-platform venv activation instructions. The activation command is Windows-specific. Issue #178 explicitly requested instructions for Windows/macOS/Linux. π Suggested fix 3. Activate the virtual environment
+
+ **Windows:**
```sh
venv\Scripts\activate
π€ Prompt for AI Agents |
||
|
|
||
| 4. Install dependencies: | ||
| ```sh | ||
| pip install -r requirements.txt | ||
| ``` | ||
|
|
||
| 3. Navigate to the app directory: | ||
| 5. Navigate to the app directory: | ||
| ```sh | ||
| cd app | ||
| ``` | ||
|
|
||
| 4. Create a `.env` file using `.env-example` as a reference. | ||
| 6. Create a `.env` file | ||
|
|
||
| 5. Obtain Supabase credentials: | ||
| - Use `.env-example` file as reference | ||
|
|
||
| 7. Obtain Supabase credentials: | ||
|
|
||
| - Go to [Supabase](https://supabase.com/) | ||
| - Log in and create a new project | ||
|
|
@@ -161,10 +172,53 @@ cd app | |
| ``` | ||
|
|
||
|
|
||
| 6. Get the Groq API key: | ||
| 8. Get the Groq API key: | ||
| - Visit [Groq Console](https://console.groq.com/) | ||
| - Create an API key and paste it into the `.env` file | ||
|
|
||
| 9. Get the Gemini API key: | ||
| - Visit [Google AI Studio](https://aistudio.google.com/) | ||
| - SignIn/SignUp with Google account | ||
| - Click "API Keys" left side panel | ||
| - Click "Create API Key" | ||
| - Name your key "..." and select "Default Gemini Project" | ||
| - Click "Create key" | ||
| - Paste the API Key into the `.env` file | ||
|
|
||
| 10. Final `.env` file should look: | ||
|
|
||
| ```sh | ||
| SUPABASE_URL=[URL] | ||
| SUPABASE_KEY=[URL] | ||
|
|
||
| user=postgres | ||
| password=[YOUR-PASSWORD] | ||
| host=db.wveftanaurduixkyijhf.supabase.co | ||
| port=5432 | ||
| dbname=postgres | ||
|
|
||
| GROQ_API_KEY=[URL] | ||
|
|
||
| GEMINI_API_KEY=[URL] | ||
| ``` | ||
|
|
||
| [The above works in ipv6 networks, if you are in ipv4 network or it cause errors, use the below connection string which could be found in Session Pooler connection] | ||
|
|
||
| ```sh | ||
| SUPABASE_URL=[URL] | ||
| SUPABASE_KEY=[URL] | ||
|
|
||
| user=postgres.<project> | ||
| password=[YOUR-PASSWORD] | ||
| host=aws-<location>.pooler.supabase.com | ||
| port=5432 | ||
| dbname=postgres | ||
|
|
||
| GROQ_API_KEY=[URL] | ||
|
|
||
| GEMINI_API_KEY=[URL] | ||
| ``` | ||
|
Comment on lines
+199
to
+231
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Final Step 9 documents obtaining the YouTube API key, and π Suggested fix (showing IPv6 block; apply same to IPv4 block) ```sh
SUPABASE_URL=[URL]
- SUPABASE_KEY=[URL]
+ SUPABASE_KEY=[YOUR-SUPABASE-KEY]
user=postgres
password=[YOUR-PASSWORD]
host=db.wveftanaurduixkyijhf.supabase.co
port=5432
dbname=postgres
- GROQ_API_KEY=[URL]
+ GROQ_API_KEY=[YOUR-GROQ-API-KEY]
- GEMINI_API_KEY=[URL]
+ GEMINI_API_KEY=[YOUR-GEMINI-API-KEY]
+
+ YOUTUBE_API_KEY=[YOUR-YOUTUBE-API-KEY]
```π€ Prompt for AI Agents |
||
|
|
||
| #### 4. Start Development Servers | ||
|
|
||
|
|
||
|
|
@@ -173,9 +227,9 @@ cd app | |
| npm run dev | ||
| ``` | ||
|
|
||
| 2. Start the backend server (from the backend/app directory): | ||
| 2. Start the backend server (from the backend directory): | ||
| ```sh | ||
| uvicorn main:app --reload | ||
| uvicorn app.main:app --reload | ||
| ``` | ||
|
|
||
| ## Data Population | ||
|
|
||
Uh oh!
There was an error while loading. Please reload this page.