Skip to content

Commit

Permalink
improvement: singlestore readme
Browse files Browse the repository at this point in the history
  • Loading branch information
manthanguptaa committed Dec 6, 2024
1 parent 315c714 commit 4908fc9
Show file tree
Hide file tree
Showing 2 changed files with 24 additions and 8 deletions.
30 changes: 22 additions & 8 deletions cookbook/integrations/singlestore/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,18 +13,32 @@ source ~/.venvs/aienv/bin/activate
pip install -U pymysql sqlalchemy pypdf openai phidata
```

3. Add credentials
3. Run SingleStore

- For SingleStore
```shell
docker run \
-d --name singlestoredb-dev \
-e ROOT_PASSWORD="admin" \
-p 3306:3306 -p 8080:8080 -p 9000:9000 \
--platform linux/amd64 \
ghcr.io/singlestore-labs/singlestoredb-dev:latest
```

4. Create the database

> Note: If using a shared tier, please provide a certificate file for SSL connection [Read more](https://docs.singlestore.com/cloud/connect-to-singlestore/connect-with-mysql/connect-with-mysql-client/connect-to-singlestore-helios-using-tls-ssl/)
- Visit http://localhost:8080 and login with `root` and `admin`
- Create the database with your choice of name

5. Add credentials

- For SingleStore

```shell
export SINGLESTORE_HOST="host"
export SINGLESTORE_PORT="3333"
export SINGLESTORE_USERNAME="user"
export SINGLESTORE_PASSWORD="password"
export SINGLESTORE_DATABASE="db"
export SINGLESTORE_HOST="localhost"
export SINGLESTORE_PORT="3306"
export SINGLESTORE_USERNAME="root"
export SINGLESTORE_PASSWORD="admin"
export SINGLESTORE_DATABASE="your_database_name"
export SINGLESTORE_SSL_CA=".certs/singlestore_bundle.pem"
```

Expand Down
2 changes: 2 additions & 0 deletions cookbook/integrations/singlestore/agent.py
Original file line number Diff line number Diff line change
Expand Up @@ -40,3 +40,5 @@
# Enable the agent to read the chat history
read_chat_history=True,
)

agent.print_response("How do I make pad thai?", markdown=True)

0 comments on commit 4908fc9

Please sign in to comment.