std::optional< std::string > text
The text, where the value is a string literal or a name bound to one.
Definition discover.cc:596
Definition transform.cc:27
absl::StatusOr< std::string > Expand(std::string_view encoded, size_t max_bytes)
Expand a context encoding, enforcing the expanded byte limit.
Definition transform.cc:169
absl::StatusOr< std::string > CompactJson(std::string_view text, size_t max_bytes, size_t max_depth)
Return JSON with representation whitespace removed, preserving all tokens.
Definition transform.cc:44
size_t EstimateTokens(std::string_view text)
Estimate tokens from UTF-8 bytes; this is not a provider tokenizer.
Definition transform.cc:240
absl::StatusOr< std::string > Encode(std::string_view text, std::string_view format, size_t max_bytes)
Encode repeated lines or JSON key lexemes in a reversible JSON envelope.
Definition transform.cc:90