TensaCo / tensacode

2 stars 1 forks source link

First class SQL support? #5

Open JacobFV opened 1 year ago

JacobFV commented 1 year ago
JacobFV commented 1 year ago

This might look like

with SQLiteModel(...):
   records = tc.get('uses in Dallas')
   records = tc.update('tally up the total runs for each user', records)
   tc.put('save the total runs', records)

And the class hierarchy might look like:

SQLiteModel > SQLModel > LLMBasedModel > BaseModel
JacobFV commented 1 year ago

However the above approach doesn't feel correct, since we might equally wish to use an NN-based model instead of an LLM-based one.

Perhaps, the SQL layer should be an wrapper around the model layer. Something like:

with SQLiteModel(..., model=tc.CURRENT_MODEL):
   ...