-
Notifications
You must be signed in to change notification settings - Fork 28
Open
Description
Issue: JSON Syntax Error in Looker ExtGenAI Logging Filter
Description
While executing an SQL query in Looker ExtGenAI logging filter, we encountered a JSON syntax error. The error message indicates that there is an invalid control character (U+000A - line feed) in the JSON string, which needs to be escaped.
Query
#Looker ExtGenAI logging filter Fields - v: 3.0
BEGIN
INSERT INTO llm.explore_logging(creation_timestamp, userInput, modelFields, llmResult, thumbsUpDownNone) VALUES(
CURRENT_TIMESTAMP(),
'¿Cuales son los tipos de tecnología?',
JSON '[{"label":"Cuenta Atributo","name":"dm_cuenta_m.cuenta_atributo","type":"string","description":"Indica el atributo de la cuenta (ejemplo influencer, vip, prensa, etc)."},{"label":"Cuenta Ciclo Facturacion","name":"dm_cuenta_m.cuenta_ciclo_facturacion","type":"string","description":""},{"label":"Cuenta Cliente Ciclo Facturacion","name":"dm_cliente_m.cliente_ciclo_facturacion","type":"string","description":""},{"label":"Cuenta Cliente Codigo Integracion","name":"dm_cliente_m.cliente_codigo_integracion","type":"string","description":"Corresponde al Código de cliente de 10 dígitos."},{"label":"Cuenta Cliente Codigo Integracion Texto","name":"dm_cliente_m.cliente_codigo_integracion_texto","type":"string","description":""},{"label":"Cuenta Cliente Cuit","name":"dm_cliente_m.cliente_cuit","type":"string","description":""},{"label":"Cuenta Cliente Email","name":"dm_cliente_m.cliente_email","type":"string","description":""},{"label":"Cuenta Cliente Razon Social","name":"dm_cliente_m.cliente_razon_social","type":"string","description":""},{"label":"Cuenta Cliente SRCId","name":"dm_cliente_m.cliente_srcid","type":"string","description":""},{"label":"Cuenta Cliente Segmento 1 Nombre","name":"dm_cliente_"}]',
JSON '{"field_names":["ft_parque.producto_adquirido_tecnologia"],"filters":{},"sorts":[],"limit":"500","pivots":[]}',
0
);
SELECT 1;
END
Error Message
Query error: Invalid JSON literal: syntax error while parsing value - invalid string: control character U+000A (LF) must be escaped to \u000A or \n; last read: '"Negocio Fija/Movil - Cuenta Total Clientes unicos.<U+000A>' at [6:17]
Steps to Reproduce
- Execute the above SQL query in the Looker ExtGenAI logging filter.
- Observe the JSON syntax error in the response.
Expected Behavior
The SQL query should execute successfully without any JSON syntax errors.
Metadata
Metadata
Assignees
Labels
No labels