Skip to content

Commit

Permalink
added usage example and minor fixes (#10)
Browse files Browse the repository at this point in the history
  • Loading branch information
anisbhsl authored Aug 25, 2023
1 parent 02f6e30 commit 241eaea
Show file tree
Hide file tree
Showing 4 changed files with 32 additions and 3 deletions.
29 changes: 29 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,38 @@ A python library to handle communication with Sinequa REST API.
```
$ pip install pynequa
```

## Example Usage
```
import pynequa
from pynequa.models import QueryParams
# provide following config parameters
config = {
"base_url": "",
"app_name": "",
"access_token":"",
"query_name": ""
}
#initialize a Sinequa connector instance
sinequa=pynequa.Sinequa(config=config)
params = QueryParams()
params.search_text = "<your_search_text>"
..... #other params
#perform a search query operation
results=sinequa.search_query(params)
```


## Feature Roadmap
Implement following REST endpoints to manage requests with Sinequa API.




**Search Endpoints:**
- [x] search.app
- [x] search.dataset
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[project]
name = "pynequa"
version = "0.1.0"
version = "0.1.1"
authors = [
{ name="Anish Bhusal", email="[email protected]" },
]
Expand Down
2 changes: 1 addition & 1 deletion requirements.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
pytest==7.1.1
Requests==2.31.0
setuptools==61.2.0
sphinx-click==4.4.0
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
from setuptools import setup, find_packages

VERSION = '0.1.0'
VERSION = '0.1.1'
requirements = []
test_requirements = ['pytest>=3']

Expand Down

0 comments on commit 241eaea

Please sign in to comment.