Commit Graph

4046 Commits

Author SHA1 Message Date
Timothy Jaeryang Baek
d0e51bde5d refac 2026-04-24 15:03:29 +09:00
Timothy Jaeryang Baek
4dc5c1eb4f refac 2026-04-24 15:00:47 +09:00
tcx4c70
f6bd08c852 fix(utils): Switch throttle decorator to async (#23979)
After migration to async db operations, the throttle decorator also
needs to support async. Since the decorator is only used for async funcs
now, we can just switch it to async instead of supporting sync and async
at the same time.

Signed-off-by: Adam Tao <tcx4c70@gmail.com>
2026-04-24 14:39:45 +09:00
Timothy Jaeryang Baek
116eb7fc55 refac 2026-04-21 16:05:26 +09:00
Timothy Jaeryang Baek
65f55847a1 refac 2026-04-21 16:04:48 +09:00
Timothy Jaeryang Baek
6cc799b1bb chore: format 2026-04-21 15:52:00 +09:00
Timothy Jaeryang Baek
b9fc3f367a refac 2026-04-21 15:47:32 +09:00
Timothy Jaeryang Baek
c7b6de6ca4 refac 2026-04-21 15:41:07 +09:00
Timothy Jaeryang Baek
c4aac0415c refac 2026-04-21 14:58:28 +09:00
Timothy Jaeryang Baek
a27916d1db refac 2026-04-21 14:31:04 +09:00
Timothy Jaeryang Baek
65834432a3 refac 2026-04-21 13:51:39 +09:00
Timothy Jaeryang Baek
46d73c9dcd refac 2026-04-21 13:46:39 +09:00
Timothy Jaeryang Baek
a2875f13c6 refac 2026-04-21 13:33:33 +09:00
Timothy Jaeryang Baek
e88e565ab4 refac 2026-04-21 13:18:54 +09:00
Timothy Jaeryang Baek
b645b0dc23 refac 2026-04-20 18:47:53 +09:00
Tim Baek
51627555bf refac 2026-04-20 03:35:17 -04:00
Timothy Jaeryang Baek
5127354b3e refac 2026-04-20 09:21:30 +09:00
Timothy Jaeryang Baek
f246a66810 refac 2026-04-20 09:10:48 +09:00
Timothy Jaeryang Baek
47329b5032 refac 2026-04-20 08:55:34 +09:00
Timothy Jaeryang Baek
d5e69f182c refac 2026-04-20 08:53:06 +09:00
Timothy Jaeryang Baek
e29d145a1c refac 2026-04-20 08:48:35 +09:00
Classic298
b3ca943da1 perf(channels): batch user lookup in model_response_handler thread history (#23795)
* perf(channels): batch user lookup in model_response_handler thread history

The thread-history builder in model_response_handler called
Users.get_user_by_id once per thread message (deduped via an intra-loop
dict), producing N individual SELECTs for a thread of N unique authors.

Replace with a single Users.get_users_by_user_ids call that returns all
authors in one WHERE id IN (...) query, matching the batch pattern
already used elsewhere in this file (lines 739, 804, 1320).

Behavior is preserved: deleted users still resolve to None and fall
through to the existing 'Unknown' fallback via .get().

* refac(channels): rename loop vars to full words per review

Address reviewer feedback to use descriptive names `message` and `user`
instead of single-letter `m` and `u` in the batch user-lookup
comprehensions.

---------

Co-authored-by: Claude <noreply@anthropic.com>
2026-04-20 08:37:07 +09:00
Timothy Jaeryang Baek
56c5bc1d34 refac 2026-04-20 08:36:24 +09:00
Timothy Jaeryang Baek
fd25152076 refac 2026-04-20 08:34:15 +09:00
Timothy Jaeryang Baek
24dd5b461e refac 2026-04-20 00:09:24 +09:00
Timothy Jaeryang Baek
1d501cfa3f refac 2026-04-20 00:07:34 +09:00
Timothy Jaeryang Baek
a05a769938 refac 2026-04-19 23:42:09 +09:00
Timothy Jaeryang Baek
e5b5a17426 refac 2026-04-19 23:38:58 +09:00
Timothy Jaeryang Baek
37eba1c5a6 chore: format 2026-04-19 22:45:54 +09:00
Timothy Jaeryang Baek
5afc258c5b refac 2026-04-19 22:37:10 +09:00
Timothy Jaeryang Baek
42694c7c0c refac 2026-04-19 22:33:32 +09:00
Timothy Jaeryang Baek
f45d0f130e refac 2026-04-19 22:22:15 +09:00
Timothy Jaeryang Baek
98627e42b4 refac 2026-04-19 22:13:47 +09:00
Timothy Jaeryang Baek
4a5401b417 refac 2026-04-19 21:48:27 +09:00
Timothy Jaeryang Baek
8d739e2aba feat: calendar 2026-04-19 19:15:05 +09:00
Timothy Jaeryang Baek
a4d62253df refac 2026-04-18 06:23:50 +09:00
Timothy Jaeryang Baek
7cfb260b8a refac 2026-04-17 15:01:42 +09:00
Timothy Jaeryang Baek
49430de42d refac 2026-04-17 15:00:17 +09:00
Classic298
f0e0cfcf02 perf: avoid redundant knowledge re-fetch in update_knowledge_access_by_id (#23799)
After set_access_grants, the handler was reloading the same knowledge
record via get_knowledge_by_id, which triggers an extra SELECT plus a
nested fetch of access grants. set_access_grants already returns the
newly-written grants and the local knowledge object is otherwise
unchanged, so update it in place and reuse it for the response.

https://claude.ai/code/session_01S18Lgqbih7Ry2JZUUv8TxF

Co-authored-by: Claude <noreply@anthropic.com>
2026-04-17 14:44:42 +09:00
Timothy Jaeryang Baek
55bfc7cbc2 refac 2026-04-17 14:35:13 +09:00
Timothy Jaeryang Baek
4113b15a60 chore: format 2026-04-17 14:28:18 +09:00
Timothy Jaeryang Baek
8acce144f9 refac 2026-04-17 14:15:36 +09:00
Timothy Jaeryang Baek
e7e752f8e7 refac 2026-04-17 14:09:35 +09:00
Timothy Jaeryang Baek
f44b7a01f5 refac 2026-04-17 13:59:46 +09:00
Timothy Jaeryang Baek
2c7acb9285 refac 2026-04-17 13:58:32 +09:00
Timothy Jaeryang Baek
50363ba66b refac 2026-04-17 13:52:11 +09:00
Timothy Jaeryang Baek
860b90fd17 refac 2026-04-17 13:47:21 +09:00
Timothy Jaeryang Baek
914ccf07ef refac 2026-04-17 13:37:52 +09:00
Timothy Jaeryang Baek
ba83613ff2 refac 2026-04-17 13:35:35 +09:00
Timothy Jaeryang Baek
499129625b refac
Co-Authored-By: Classic298 <27028174+Classic298@users.noreply.github.com>
2026-04-17 13:33:11 +09:00