1345 Commits

Author SHA1 Message Date
Yuan
0af2222cb4 docs: add deploy to cloud run instructions (#36)
Instructions to deploy Toolbox to Cloud Run.

---------

Co-authored-by: Kurtis Van Gent <31518063+kurtisvg@users.noreply.github.com>
Co-authored-by: Anubhav Dhawan <anubhavdhawan@google.com>
2024-11-11 09:10:43 -08:00
Anubhav Dhawan
1833fee5bc docs(langchain-sdk): update README file (#54) 2024-11-08 21:21:37 +00:00
Anubhav Dhawan
1b57ecab0d doc: Create a README file explaining the setup and sample usage with LangChain and LangGraph. (#45) 2024-11-08 13:49:16 -07:00
Twisha Bansal
1cf0d96e58 Update client.py (#51)
Minor fix
2024-11-07 10:39:39 -07:00
Twisha Bansal
b824abe72f feat: LlamaIndex SDK (#48)
Added client code for LlamaIndex SDK.

Will add README and tests in a follow up PR.
2024-11-07 05:04:09 +00:00
Twisha Bansal
972888b9d6 fix(docs): correct outdated references to tool kinds (#49) 2024-11-06 11:27:14 -07:00
Kurtis Van Gent
52ebb431b7 fix: correct source type validation for postgres-sql tool (#47)
Fixes a bug introduced in #43 where postgres-tool didn't think any of
the sources were valid.

The root cause of the bug was inconsistent usage of pointer/value in the
receiver functions. The fix updates everything to consistently use a
pointer receiver function.
2024-11-05 12:25:21 -07:00
Kurtis Van Gent
621f2c61f9 chore(docs): fix reference to pg-sql page (#44) 2024-11-01 23:22:09 +00:00
Kurtis Van Gent
f630965937 feat!: consolidate "x-postgres-generic" tools to "postgres-sql" tool (#43)
This PR introduces the following breaking change: The
`alloydb-pg-generic`, `cloud-sql-pg-generic`, and
`postgres-generic-tool` have been replaced by the `postgres-sql` tool,
which works with all 3 Postgres sources.

If you were using of the the previous tools, you will need to update it
as follows:
```diff
example_tool:
-    kind: cloud-sql-pg-generic
+    kind: postgres-sql
     source: my-cloud-sql-pg-instance
     description: some description
        statement: |
            SELECT * FROM SQL_STATEMENT;
        parameters:
        - name: country
          type: string
          description: some description
```

I'm proposing this change for the following reasons:
1. It provides greater flexibility between postgres-compatible sources
-- you can change between "postgres" and "alloydb-postgres" without
issue
2. The name "postgres-sql" is more clear that "postgres-generic" -- it
indicates it's a tool that runs SQL on the source
3. It's easier for us to maintain feature compatibility across a single
"postgres-sql" tool
2024-11-01 16:17:18 -07:00
Kurtis Van Gent
0a0d206efd docs: add documentation for tools (#40)
Adds more detailed documentation on tools and parameters.
2024-11-01 17:03:51 -06:00
Kurtis Van Gent
efe9e8bc97 chore: refactor sources/tools each into their own package (#42)
Moves all of the "source" and "tool" implementations into their own
packages. This layout makes it a bit more clear where the
implementations are, and seems likely to scale more cleanly as more
sources and tools are added.
2024-11-01 16:44:13 -06:00
Yuan
b08072a800 feat(container): add entrypoint in Dockerfile (#38)
Update binary file name within Dockerfile.
Add /app directory to mount volumes.
2024-10-31 13:33:51 -07:00
Kurtis Van Gent
bf85e6f2fc docs: add detailed documentation for sources (#37)
Adds more detailed documentation for sources.
2024-10-31 20:25:12 +00:00
Yuan
4f0335a733 docs: add developer.md (#29) 2024-10-31 12:03:22 -07:00
Yuan
0396524925 chore: deduplicate postgres implementations (#34) 2024-10-29 15:18:57 -07:00
Yuan
2e0dbbd20a ci: add script to generate release table (#32)
Co-authored-by: Kurtis Van Gent <31518063+kurtisvg@users.noreply.github.com>
2024-10-29 13:57:12 -07:00
Kurtis Van Gent
cf8112f856 fix: handle content-type correctly (#33)
Fixes a bug where the content-type wasn't being set correctly in the
response type.
2024-10-29 20:00:22 +00:00
release-please[bot]
7e8b870d35 chore(main): release 0.0.1 (#16)
🤖 I have created a release *beep* *boop*
---


## 0.0.1 (2024-10-28)


### Features

* Add address and port flags
([#7](https://github.com/googleapis/genai-toolbox/issues/7))
([df9ad9e](df9ad9e33f))
* Add AlloyDB source and tool
([#23](https://github.com/googleapis/genai-toolbox/issues/23))
([fe92d02](fe92d02ae2))
* Add basic CLI
([#5](https://github.com/googleapis/genai-toolbox/issues/5))
([1539ee5](1539ee56dd))
* Add basic http server
([#6](https://github.com/googleapis/genai-toolbox/issues/6))
([e09ae30](e09ae30a90))
* Add basic parsing from tools file
([#8](https://github.com/googleapis/genai-toolbox/issues/8))
([b9ba364](b9ba364fb6))
* Add initial cloud sql pg invocation
([#14](https://github.com/googleapis/genai-toolbox/issues/14))
([3703176](3703176fce))
* Add Postgres source and tool
([#25](https://github.com/googleapis/genai-toolbox/issues/25))
([2742ed4](2742ed48b8))
* Add preliminary parsing of parameters
([#13](https://github.com/googleapis/genai-toolbox/issues/13))
([27edd3b](27edd3b5f6))
* Add support for array type parameters
([#26](https://github.com/googleapis/genai-toolbox/issues/26))
([3903e86](3903e860bc))
* Add toolset configuration
([#12](https://github.com/googleapis/genai-toolbox/issues/12))
([59b4bc0](59b4bc07f4))
* Add Toolset manifest endpoint
([#11](https://github.com/googleapis/genai-toolbox/issues/11))
([61e7b78](61e7b78ad8))
* **langchain-sdk:** Add Toolbox SDK for LangChain
([#22](https://github.com/googleapis/genai-toolbox/issues/22))
([0bcd4b6](0bcd4b6e41))
* Stub basic control plane functionality
([#9](https://github.com/googleapis/genai-toolbox/issues/9))
([336bdc4](336bdc4d56))


### Miscellaneous Chores

* Release 0.0.1
([#31](https://github.com/googleapis/genai-toolbox/issues/31))
([1f24ddd](1f24dddb4b))


### Continuous Integration

* Add realease-please
([#15](https://github.com/googleapis/genai-toolbox/issues/15))
([17fbbb4](17fbbb49b0))

---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).

Co-authored-by: release-please[bot] <55107282+release-please[bot]@users.noreply.github.com>
v0.0.1
2024-10-28 10:31:23 -06:00
Yuan
2742ed48b8 feat: add Postgres source and tool (#25) 2024-10-28 10:13:18 -06:00
Yuan
1f24dddb4b chore: release 0.0.1 (#31)
Release-As: 0.0.1
2024-10-28 08:59:00 -07:00
Anubhav Dhawan
0bcd4b6e41 feat(langchain-sdk): Add Toolbox SDK for LangChain (#22)
Adds a initial python SDK for interacting with Toolbox from LangChain.
2024-10-28 09:50:41 -06:00
Yuan
5f565e43df chore: fix typo (#30) 2024-10-25 16:20:38 -07:00
Yuan
fe92d02ae2 feat: add AlloyDB source and tool (#23) 2024-10-25 16:12:02 -07:00
Kurtis Van Gent
6d40a1df79 docs: add instructions to README (#28) 2024-10-25 22:07:11 +00:00
Kurtis Van Gent
3903e860bc feat: add support for array type parameters (#26)
Adds support for "array" type parameters. Uses a subet of JSONSchema for
specification, in that arrays can be specified in the following way:

```yaml
parameters:
    name: "my_array"
    type: "array"
    description: "some description"
    items:
       type: "integer"
```
2024-10-25 21:54:14 +00:00
Yuan
91664d2cb7 ci: update release cloudbuild (#21)
Renamed file.
Update versioned release cloudbuild config file to include version tags.
Added other OS and architecture binary.
2024-10-25 10:00:39 -07:00
Kurtis Van Gent
de14c6f669 chore: refactor parameters logic to allow for more complex functionality (#24)
Refactors parameter logic to allow for more complex functionality (e.g.
arrays) in the future.

---------

Co-authored-by: Wenxin Du <117315983+duwenxin99@users.noreply.github.com>
2024-10-23 13:04:10 -06:00
Yuan
546ca41237 ci: Add cloudbuild for release (#19) 2024-10-18 15:10:14 -07:00
Yuan
ba4c566ab8 chore: remove secrets from github (#20) 2024-10-18 10:58:22 -07:00
Wenxin Du
61e7b78ad8 feat: Add Toolset manifest endpoint (#11)
1. Calculate tool manifests when server starts.
2. Add toolset manifest endpoints.

---------

Co-authored-by: Kurtis Van Gent <31518063+kurtisvg@users.noreply.github.com>
2024-10-17 18:43:58 -04:00
Yuan
26ed13561a ci: Add Dockerfile for container images (#17)
Co-authored-by: Kurtis Van Gent <31518063+kurtisvg@users.noreply.github.com>
2024-10-17 13:24:21 -07:00
Yuan
17fbbb49b0 ci: add realease-please (#15)
Release-As: 0.1.0
2024-10-15 09:13:05 -07:00
Kurtis Van Gent
3703176fce feat: add initial cloud sql pg invocation (#14)
Makes the following changes:
- Fills in previously stubbed "Invoke()" function for the Cloud SQL
Generic Tool
- Updates API to /{tool_name}/invoke to for invocation of said tool 
- Updates response to use JSON 
- Correctly returns error messages for invalid http codes
2024-10-15 09:53:01 -06:00
Wenxin Du
59b4bc07f4 feat: add toolset configuration (#12)
Add `Toolset` implementation to the `tools` package:
- struct and configs.
- Custom `UnmarshalYAML` function.
- Initialization function that validates if tools specified for the
toolset exist.
2024-10-11 14:11:05 -04:00
Kurtis Van Gent
27edd3b5f6 feat: add preliminary parsing of parameters (#13)
This PR adds preliminary parsing of parameters. Currently it only
supports 4 types: string, int, float32, and bool. Almost certainly we
will need to introduce more complicated parsing configuration (to handle
objects and arrays), but my initial attempts got quickly complicated, so
I simplified in the short term.

This also makes 2 breaking changes to config.yaml:
- changes "parameters" to be a list over object -- this is because
parameter ordering is important, and needs to be preserved
- removed the "required" field from parameter objects -- we need to
determine how to handle optional parameters in SQL queries
2024-10-08 15:18:49 -06:00
Kurtis Van Gent
336bdc4d56 feat: stub basic control plane functionality (#9)
Stub's out some basic control plane functionality. This also required
setting up some Source and Tools initialization.
2024-09-20 14:12:16 -06:00
Kurtis Van Gent
b9ba364fb6 feat: add basic parsing from tools file (#8) 2024-08-05 09:33:07 -06:00
Kurtis Van Gent
df9ad9e33f feat: add address and port flags (#7)
Add flags for setting the address and port of the server.
2024-07-30 10:55:13 -05:00
Kurtis Van Gent
e09ae30a90 feat: add basic http server (#6) 2024-07-26 16:59:01 -05:00
Kurtis Van Gent
1539ee56dd feat: add basic CLI (#5) 2024-07-15 11:12:29 -06:00
Kurtis Van Gent
39b6b58d89 ci: disable auto-label (#4) 2024-07-15 11:05:11 -06:00
Kurtis Van Gent
627158ceb1 ci: add path to labels file (#3) 2024-07-12 16:20:40 -07:00
Kurtis Van Gent
2fa93f3f70 ci: use consistent permissions in workflows (#2) 2024-07-12 17:08:45 -06:00
Kurtis Van Gent
0adb59c273 chore(ci): set up ci 2024-07-12 16:42:13 -06:00
Kurtis Van Gent
a612765c85 chore: init project 2024-06-07 21:29:24 +00:00