Skip to content

Commit

Permalink
Documentation for storage type (#508)
Browse files Browse the repository at this point in the history
* Documentation for storage type is added.

* Removed deprecate warning and added note for beta.
  • Loading branch information
shreyas-damle authored Aug 28, 2024
1 parent feb1926 commit 4291404
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 5 deletions.
7 changes: 7 additions & 0 deletions docs/gh_pages/docs/config.md
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,11 @@ Notes:

- `anonymizeSnippets`: Flag to anonymize snippets in report. Possible values are 'True' and 'False'. When its value is 'True', snippets in reports will be shown as anonymized and vice versa.

### Storage
This is beta feature introduced in 0.1.18.
- `type`: Specifies storage type to store states of the GenAI applications. Possible values are `file` or `db`. Default value is `file`. By default SQLite database is used when we set it as `db`.
- `type` as `file` is deprecated, use `type` as `db`. `file` would not be supported from 0.1.19 release.

### Default Configuration

```yaml
Expand All @@ -54,6 +59,8 @@ reports:
outputDir: ~/.pebblo
classifier:
anonymizeSnippets: False
storage:
type: file
```
`Note`:
Expand Down
5 changes: 0 additions & 5 deletions pebblo/app/config/config_validation.py
Original file line number Diff line number Diff line change
Expand Up @@ -54,11 +54,6 @@ def validate(self):
f"Valid values are {valid_storage_types}"
)

# Set deprecated warning message for file storage type
if storage_type == StorageTypes.FILE.value:
deprecate_error = f"DeprecationWarning: '{storage_type}' Storage Type will be deprecated starting from Pebblo version 0.0.19, use '{StorageTypes.DATABASE.value}' instead"
print(deprecate_error)

if storage_type == StorageTypes.DATABASE.value:
db_type = self.config.get("db")
default_location = self.config.get("location")
Expand Down

0 comments on commit 4291404

Please sign in to comment.