alpaca-core / ac-local

Alpaca Core local inference SDK
MIT License
1 stars 0 forks source link

Change C API interface to use `ac_dict_root` instead of json strings #49

Closed iboB closed 2 months ago

iboB commented 2 months ago

Currently the interface only supports json strings. Add an ac_dict_root-based interface. It should take ownership of the the provided root (and free it accordingly) to transfer to the underlying C++ code

iboB commented 2 months ago

In fact I think it would be better to ditch the "overloads" and just entirely change the interface to use ac_dict_root. Yes, this incurs an additional allocation, but it should be minor compared to the rest of what's going on.