Open-Assistant icon indicating copy to clipboard operation
Open-Assistant copied to clipboard

Add performance tracking to the bot.

Open AlexanderHott opened this issue 2 years ago • 3 comments

There is currently no way to visualize the data, but a script or command can be added if necessary.

AlexanderHott avatar Jan 02 '23 09:01 AlexanderHott

LGTM Two independent questions:

  • why is _post now private?
  • is it at least conceivable that we use some kind of db-framework in the future (e.g. sqlmodel+alembic, etc.) instead of raw sql, or is there a technical reason against this?

I see it as users should only interact with the direct methods like fetch_task, ack_task, and post_interaction. This is not meant to be used as a regular http client.

AlexanderHott avatar Jan 02 '23 20:01 AlexanderHott

Logging bot perf will become important when I start tuning the cache settings. Hikari's cache is very powerful, but we need to be careful because some categories (like presence) take up a lot of memory.

I guess tracking API calls isn't too useful right now. If you really don't want it, I can remove it.

AlexanderHott avatar Jan 02 '23 20:01 AlexanderHott

Logging bot perf will become important when I start tuning the cache settings. Hikari's cache is very powerful, but we need to be careful because some categories (like presence) take up a lot of memory.

OK, sounds reasonable.

I guess tracking API calls isn't too useful right now. If you really don't want it, I can remove it.

OasstApiClient has been moved ot oaast-shared. I suggest simply using it as it is right now. I hope exception parsing will also soon be added so that cllients see `OasstError´ exceptions with message and internal code.

andreaskoepf avatar Jan 02 '23 21:01 andreaskoepf