shreemaan-abhishek commented on code in PR #14044:
URL: https://github.com/apache/apisix/pull/14044#discussion_r4375016344
##########
apisix/plugins/ai-protocols/bedrock-converse.lua:
##########
@@ -30,6 +30,31 @@ local table = table
local _M = {}
+local function cache_token_count(raw, key, alias)
Review Comment:
nit: this fallback based value extraction logic _may_ appear in other
request/response structures in bedrock API. So you might wanna name this
function get_with_fallback or get_with_alias... so next time when we encounter
similar issue we will reuse this function instead of creating new ones.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]