chat completion, testing

# What does this PR do?


## Test Plan
# What does this PR do?


## Test Plan
This commit is contained in:
Eric Huang 2025-05-22 21:44:14 -07:00
parent 8feb1827c8
commit ecd8f2113a
27 changed files with 6729 additions and 38 deletions

View file

@ -0,0 +1,8 @@
export function truncateText(
text: string | null | undefined,
maxLength: number = 50,
): string {
if (!text) return "N/A";
if (text.length <= maxLength) return text;
return text.substring(0, maxLength) + "...";
}