From ab407e791d5c1f9e3c36185bc8b48ecd316cedab Mon Sep 17 00:00:00 2001 From: "zhuangjiaqi.777" Date: Wed, 31 Dec 2025 11:41:56 +0800 Subject: [PATCH 1/4] chore: gen code --- backend/go.mod | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) diff --git a/backend/go.mod b/backend/go.mod index 27b853e23..90bacf257 100644 --- a/backend/go.mod +++ b/backend/go.mod @@ -96,7 +96,21 @@ require ( gorm.io/plugin/soft_delete v1.2.1 ) -require github.com/grpc-ecosystem/grpc-gateway/v2 v2.27.2 // indirect +require ( + github.com/Masterminds/goutils v1.1.1 // indirect + github.com/Masterminds/sprig/v3 v3.2.3 // indirect + github.com/cloudwego/hertz/cmd/hz v0.9.7 // indirect + github.com/cpuguy83/go-md2man/v2 v2.0.2 // indirect + github.com/dlclark/regexp2 v1.11.4 // indirect + github.com/grpc-ecosystem/grpc-gateway/v2 v2.27.2 // indirect + github.com/huandu/xstrings v1.3.3 // indirect + github.com/imdario/mergo v0.3.12 // indirect + github.com/mitchellh/copystructure v1.0.0 // indirect + github.com/mitchellh/reflectwalk v1.0.0 // indirect + github.com/russross/blackfriday/v2 v2.1.0 // indirect + github.com/urfave/cli/v2 v2.23.0 // indirect + github.com/xrash/smetrics v0.0.0-20201216005158-039620a65673 // indirect +) require ( github.com/brianvoe/gofakeit/v6 v6.28.0 From b334e36cedef0b679ef2db61275f79e6f9c47bfd Mon Sep 17 00:00:00 2001 From: "zhuangjiaqi.777" Date: Wed, 31 Dec 2025 11:42:51 +0800 Subject: [PATCH 2/4] chore: gen code --- backend/go.mod | 16 +--------------- 1 file changed, 1 insertion(+), 15 deletions(-) diff --git a/backend/go.mod b/backend/go.mod index 90bacf257..27b853e23 100644 --- a/backend/go.mod +++ b/backend/go.mod @@ -96,21 +96,7 @@ require ( gorm.io/plugin/soft_delete v1.2.1 ) -require ( - github.com/Masterminds/goutils v1.1.1 // indirect - github.com/Masterminds/sprig/v3 v3.2.3 // indirect - github.com/cloudwego/hertz/cmd/hz v0.9.7 // indirect - github.com/cpuguy83/go-md2man/v2 v2.0.2 // indirect - github.com/dlclark/regexp2 v1.11.4 // indirect - github.com/grpc-ecosystem/grpc-gateway/v2 v2.27.2 // indirect - github.com/huandu/xstrings v1.3.3 // indirect - github.com/imdario/mergo v0.3.12 // indirect - github.com/mitchellh/copystructure v1.0.0 // indirect - github.com/mitchellh/reflectwalk v1.0.0 // indirect - github.com/russross/blackfriday/v2 v2.1.0 // indirect - github.com/urfave/cli/v2 v2.23.0 // indirect - github.com/xrash/smetrics v0.0.0-20201216005158-039620a65673 // indirect -) +require github.com/grpc-ecosystem/grpc-gateway/v2 v2.27.2 // indirect require ( github.com/brianvoe/gofakeit/v6 v6.28.0 From 629162e0fb8389aabcfd78d8b9b0df2cde049a63 Mon Sep 17 00:00:00 2001 From: "[gaoyichen.16]" <[gaoyichen.16]@bytedance.com> Date: Sat, 31 Jan 2026 16:45:11 +0800 Subject: [PATCH 3/4] [feat][backend] evaluation trace Signed-off-by: [gaoyichen.16] <[gaoyichen.16]@bytedance.com> --- .../coze/loop/data/domain/dataset/dataset.go | 78 +++++++++++++++++++ .../loop/data/domain/dataset/k-dataset.go | 56 +++++++++++++ .../evaluation/domain/eval_set/eval_set.go | 77 ++++++++++++++++++ .../evaluation/domain/eval_set/k-eval_set.go | 56 +++++++++++++ .../evaluation_set/evaluation_set_item.go | 4 +- .../domain/entity/evaluation_set_item.go | 1 + .../evaluation/infra/rpc/data/convert.go | 1 + .../coze/loop/data/domain/dataset.thrift | 3 +- .../loop/evaluation/domain/eval_set.thrift | 1 + 9 files changed, 275 insertions(+), 2 deletions(-) diff --git a/backend/kitex_gen/coze/loop/data/domain/dataset/dataset.go b/backend/kitex_gen/coze/loop/data/domain/dataset/dataset.go index 57de45e1b..4a0119b67 100644 --- a/backend/kitex_gen/coze/loop/data/domain/dataset/dataset.go +++ b/backend/kitex_gen/coze/loop/data/domain/dataset/dataset.go @@ -9003,6 +9003,8 @@ type FieldData struct { Format *FieldDisplayFormat `thrift:"format,6,optional" frugal:"6,optional,FieldDisplayFormat" form:"format" json:"format,omitempty" query:"format"` // 图文混排时,图文内容 Parts []*FieldData `thrift:"parts,7,optional" frugal:"7,optional,list" form:"parts" json:"parts,omitempty" query:"parts"` + // 关联的 trace ID + TraceID *string `thrift:"trace_id,8,optional" frugal:"8,optional,string" form:"trace_id" json:"trace_id,omitempty" query:"trace_id"` } func NewFieldData() *FieldData { @@ -9095,6 +9097,18 @@ func (p *FieldData) GetParts() (v []*FieldData) { } return p.Parts } + +var FieldData_TraceID_DEFAULT string + +func (p *FieldData) GetTraceID() (v string) { + if p == nil { + return + } + if !p.IsSetTraceID() { + return FieldData_TraceID_DEFAULT + } + return *p.TraceID +} func (p *FieldData) SetKey(val *string) { p.Key = val } @@ -9116,6 +9130,9 @@ func (p *FieldData) SetFormat(val *FieldDisplayFormat) { func (p *FieldData) SetParts(val []*FieldData) { p.Parts = val } +func (p *FieldData) SetTraceID(val *string) { + p.TraceID = val +} var fieldIDToName_FieldData = map[int16]string{ 1: "key", @@ -9125,6 +9142,7 @@ var fieldIDToName_FieldData = map[int16]string{ 5: "attachments", 6: "format", 7: "parts", + 8: "trace_id", } func (p *FieldData) IsSetKey() bool { @@ -9155,6 +9173,10 @@ func (p *FieldData) IsSetParts() bool { return p.Parts != nil } +func (p *FieldData) IsSetTraceID() bool { + return p.TraceID != nil +} + func (p *FieldData) Read(iprot thrift.TProtocol) (err error) { var fieldTypeId thrift.TType var fieldId int16 @@ -9229,6 +9251,14 @@ func (p *FieldData) Read(iprot thrift.TProtocol) (err error) { } else if err = iprot.Skip(fieldTypeId); err != nil { goto SkipFieldError } + case 8: + if fieldTypeId == thrift.STRING { + if err = p.ReadField8(iprot); err != nil { + goto ReadFieldError + } + } else if err = iprot.Skip(fieldTypeId); err != nil { + goto SkipFieldError + } default: if err = iprot.Skip(fieldTypeId); err != nil { goto SkipFieldError @@ -9361,6 +9391,17 @@ func (p *FieldData) ReadField7(iprot thrift.TProtocol) error { p.Parts = _field return nil } +func (p *FieldData) ReadField8(iprot thrift.TProtocol) error { + + var _field *string + if v, err := iprot.ReadString(); err != nil { + return err + } else { + _field = &v + } + p.TraceID = _field + return nil +} func (p *FieldData) Write(oprot thrift.TProtocol) (err error) { var fieldId int16 @@ -9396,6 +9437,10 @@ func (p *FieldData) Write(oprot thrift.TProtocol) (err error) { fieldId = 7 goto WriteFieldError } + if err = p.writeField8(oprot); err != nil { + fieldId = 8 + goto WriteFieldError + } } if err = oprot.WriteFieldStop(); err != nil { goto WriteFieldStopError @@ -9556,6 +9601,24 @@ WriteFieldBeginError: WriteFieldEndError: return thrift.PrependError(fmt.Sprintf("%T write field 7 end error: ", p), err) } +func (p *FieldData) writeField8(oprot thrift.TProtocol) (err error) { + if p.IsSetTraceID() { + if err = oprot.WriteFieldBegin("trace_id", thrift.STRING, 8); err != nil { + goto WriteFieldBeginError + } + if err := oprot.WriteString(*p.TraceID); err != nil { + return err + } + if err = oprot.WriteFieldEnd(); err != nil { + goto WriteFieldEndError + } + } + return nil +WriteFieldBeginError: + return thrift.PrependError(fmt.Sprintf("%T write field 8 begin error: ", p), err) +WriteFieldEndError: + return thrift.PrependError(fmt.Sprintf("%T write field 8 end error: ", p), err) +} func (p *FieldData) String() string { if p == nil { @@ -9592,6 +9655,9 @@ func (p *FieldData) DeepEqual(ano *FieldData) bool { if !p.Field7DeepEqual(ano.Parts) { return false } + if !p.Field8DeepEqual(ano.TraceID) { + return false + } return true } @@ -9681,6 +9747,18 @@ func (p *FieldData) Field7DeepEqual(src []*FieldData) bool { } return true } +func (p *FieldData) Field8DeepEqual(src *string) bool { + + if p.TraceID == src { + return true + } else if p.TraceID == nil || src == nil { + return false + } + if strings.Compare(*p.TraceID, *src) != 0 { + return false + } + return true +} type ObjectStorage struct { Provider *StorageProvider `thrift:"provider,1,optional" frugal:"1,optional,StorageProvider" form:"provider" json:"provider,omitempty" query:"provider"` diff --git a/backend/kitex_gen/coze/loop/data/domain/dataset/k-dataset.go b/backend/kitex_gen/coze/loop/data/domain/dataset/k-dataset.go index 4973eb0b0..5fed70c0d 100644 --- a/backend/kitex_gen/coze/loop/data/domain/dataset/k-dataset.go +++ b/backend/kitex_gen/coze/loop/data/domain/dataset/k-dataset.go @@ -5987,6 +5987,20 @@ func (p *FieldData) FastRead(buf []byte) (int, error) { goto SkipFieldError } } + case 8: + if fieldTypeId == thrift.STRING { + l, err = p.FastReadField8(buf[offset:]) + offset += l + if err != nil { + goto ReadFieldError + } + } else { + l, err = thrift.Binary.Skip(buf[offset:], fieldTypeId) + offset += l + if err != nil { + goto SkipFieldError + } + } default: l, err = thrift.Binary.Skip(buf[offset:], fieldTypeId) offset += l @@ -6129,6 +6143,20 @@ func (p *FieldData) FastReadField7(buf []byte) (int, error) { return offset, nil } +func (p *FieldData) FastReadField8(buf []byte) (int, error) { + offset := 0 + + var _field *string + if v, l, err := thrift.Binary.ReadString(buf[offset:]); err != nil { + return offset, err + } else { + offset += l + _field = &v + } + p.TraceID = _field + return offset, nil +} + func (p *FieldData) FastWrite(buf []byte) int { return p.FastWriteNocopy(buf, nil) } @@ -6143,6 +6171,7 @@ func (p *FieldData) FastWriteNocopy(buf []byte, w thrift.NocopyWriter) int { offset += p.fastWriteField5(buf[offset:], w) offset += p.fastWriteField6(buf[offset:], w) offset += p.fastWriteField7(buf[offset:], w) + offset += p.fastWriteField8(buf[offset:], w) } offset += thrift.Binary.WriteFieldStop(buf[offset:]) return offset @@ -6158,6 +6187,7 @@ func (p *FieldData) BLength() int { l += p.field5Length() l += p.field6Length() l += p.field7Length() + l += p.field8Length() } l += thrift.Binary.FieldStopLength() return l @@ -6240,6 +6270,15 @@ func (p *FieldData) fastWriteField7(buf []byte, w thrift.NocopyWriter) int { return offset } +func (p *FieldData) fastWriteField8(buf []byte, w thrift.NocopyWriter) int { + offset := 0 + if p.IsSetTraceID() { + offset += thrift.Binary.WriteFieldBegin(buf[offset:], thrift.STRING, 8) + offset += thrift.Binary.WriteStringNocopy(buf[offset:], w, *p.TraceID) + } + return offset +} + func (p *FieldData) field1Length() int { l := 0 if p.IsSetKey() { @@ -6311,6 +6350,15 @@ func (p *FieldData) field7Length() int { return l } +func (p *FieldData) field8Length() int { + l := 0 + if p.IsSetTraceID() { + l += thrift.Binary.FieldBeginLength() + l += thrift.Binary.StringLengthNocopy(*p.TraceID) + } + return l +} + func (p *FieldData) DeepCopy(s interface{}) error { src, ok := s.(*FieldData) if !ok { @@ -6381,6 +6429,14 @@ func (p *FieldData) DeepCopy(s interface{}) error { } } + if src.TraceID != nil { + var tmp string + if *src.TraceID != "" { + tmp = kutils.StringDeepCopy(*src.TraceID) + } + p.TraceID = &tmp + } + return nil } diff --git a/backend/kitex_gen/coze/loop/evaluation/domain/eval_set/eval_set.go b/backend/kitex_gen/coze/loop/evaluation/domain/eval_set/eval_set.go index 6f20e54b6..a9bc7d510 100644 --- a/backend/kitex_gen/coze/loop/evaluation/domain/eval_set/eval_set.go +++ b/backend/kitex_gen/coze/loop/evaluation/domain/eval_set/eval_set.go @@ -4859,6 +4859,7 @@ type FieldData struct { Key *string `thrift:"key,1,optional" frugal:"1,optional,string" form:"key" json:"key,omitempty" query:"key"` Name *string `thrift:"name,2,optional" frugal:"2,optional,string" form:"name" json:"name,omitempty" query:"name"` Content *common.Content `thrift:"content,3,optional" frugal:"3,optional,common.Content" form:"content" json:"content,omitempty" query:"content"` + TraceID *string `thrift:"trace_id,4,optional" frugal:"4,optional,string" form:"trace_id" json:"trace_id,omitempty" query:"trace_id"` } func NewFieldData() *FieldData { @@ -4903,6 +4904,18 @@ func (p *FieldData) GetContent() (v *common.Content) { } return p.Content } + +var FieldData_TraceID_DEFAULT string + +func (p *FieldData) GetTraceID() (v string) { + if p == nil { + return + } + if !p.IsSetTraceID() { + return FieldData_TraceID_DEFAULT + } + return *p.TraceID +} func (p *FieldData) SetKey(val *string) { p.Key = val } @@ -4912,11 +4925,15 @@ func (p *FieldData) SetName(val *string) { func (p *FieldData) SetContent(val *common.Content) { p.Content = val } +func (p *FieldData) SetTraceID(val *string) { + p.TraceID = val +} var fieldIDToName_FieldData = map[int16]string{ 1: "key", 2: "name", 3: "content", + 4: "trace_id", } func (p *FieldData) IsSetKey() bool { @@ -4931,6 +4948,10 @@ func (p *FieldData) IsSetContent() bool { return p.Content != nil } +func (p *FieldData) IsSetTraceID() bool { + return p.TraceID != nil +} + func (p *FieldData) Read(iprot thrift.TProtocol) (err error) { var fieldTypeId thrift.TType var fieldId int16 @@ -4973,6 +4994,14 @@ func (p *FieldData) Read(iprot thrift.TProtocol) (err error) { } else if err = iprot.Skip(fieldTypeId); err != nil { goto SkipFieldError } + case 4: + if fieldTypeId == thrift.STRING { + if err = p.ReadField4(iprot); err != nil { + goto ReadFieldError + } + } else if err = iprot.Skip(fieldTypeId); err != nil { + goto SkipFieldError + } default: if err = iprot.Skip(fieldTypeId); err != nil { goto SkipFieldError @@ -5032,6 +5061,17 @@ func (p *FieldData) ReadField3(iprot thrift.TProtocol) error { p.Content = _field return nil } +func (p *FieldData) ReadField4(iprot thrift.TProtocol) error { + + var _field *string + if v, err := iprot.ReadString(); err != nil { + return err + } else { + _field = &v + } + p.TraceID = _field + return nil +} func (p *FieldData) Write(oprot thrift.TProtocol) (err error) { var fieldId int16 @@ -5051,6 +5091,10 @@ func (p *FieldData) Write(oprot thrift.TProtocol) (err error) { fieldId = 3 goto WriteFieldError } + if err = p.writeField4(oprot); err != nil { + fieldId = 4 + goto WriteFieldError + } } if err = oprot.WriteFieldStop(); err != nil { goto WriteFieldStopError @@ -5123,6 +5167,24 @@ WriteFieldBeginError: WriteFieldEndError: return thrift.PrependError(fmt.Sprintf("%T write field 3 end error: ", p), err) } +func (p *FieldData) writeField4(oprot thrift.TProtocol) (err error) { + if p.IsSetTraceID() { + if err = oprot.WriteFieldBegin("trace_id", thrift.STRING, 4); err != nil { + goto WriteFieldBeginError + } + if err := oprot.WriteString(*p.TraceID); err != nil { + return err + } + if err = oprot.WriteFieldEnd(); err != nil { + goto WriteFieldEndError + } + } + return nil +WriteFieldBeginError: + return thrift.PrependError(fmt.Sprintf("%T write field 4 begin error: ", p), err) +WriteFieldEndError: + return thrift.PrependError(fmt.Sprintf("%T write field 4 end error: ", p), err) +} func (p *FieldData) String() string { if p == nil { @@ -5147,6 +5209,9 @@ func (p *FieldData) DeepEqual(ano *FieldData) bool { if !p.Field3DeepEqual(ano.Content) { return false } + if !p.Field4DeepEqual(ano.TraceID) { + return false + } return true } @@ -5181,3 +5246,15 @@ func (p *FieldData) Field3DeepEqual(src *common.Content) bool { } return true } +func (p *FieldData) Field4DeepEqual(src *string) bool { + + if p.TraceID == src { + return true + } else if p.TraceID == nil || src == nil { + return false + } + if strings.Compare(*p.TraceID, *src) != 0 { + return false + } + return true +} diff --git a/backend/kitex_gen/coze/loop/evaluation/domain/eval_set/k-eval_set.go b/backend/kitex_gen/coze/loop/evaluation/domain/eval_set/k-eval_set.go index fb1e7c174..1ea1fbc89 100644 --- a/backend/kitex_gen/coze/loop/evaluation/domain/eval_set/k-eval_set.go +++ b/backend/kitex_gen/coze/loop/evaluation/domain/eval_set/k-eval_set.go @@ -3518,6 +3518,20 @@ func (p *FieldData) FastRead(buf []byte) (int, error) { goto SkipFieldError } } + case 4: + if fieldTypeId == thrift.STRING { + l, err = p.FastReadField4(buf[offset:]) + offset += l + if err != nil { + goto ReadFieldError + } + } else { + l, err = thrift.Binary.Skip(buf[offset:], fieldTypeId) + offset += l + if err != nil { + goto SkipFieldError + } + } default: l, err = thrift.Binary.Skip(buf[offset:], fieldTypeId) offset += l @@ -3576,6 +3590,20 @@ func (p *FieldData) FastReadField3(buf []byte) (int, error) { return offset, nil } +func (p *FieldData) FastReadField4(buf []byte) (int, error) { + offset := 0 + + var _field *string + if v, l, err := thrift.Binary.ReadString(buf[offset:]); err != nil { + return offset, err + } else { + offset += l + _field = &v + } + p.TraceID = _field + return offset, nil +} + func (p *FieldData) FastWrite(buf []byte) int { return p.FastWriteNocopy(buf, nil) } @@ -3586,6 +3614,7 @@ func (p *FieldData) FastWriteNocopy(buf []byte, w thrift.NocopyWriter) int { offset += p.fastWriteField1(buf[offset:], w) offset += p.fastWriteField2(buf[offset:], w) offset += p.fastWriteField3(buf[offset:], w) + offset += p.fastWriteField4(buf[offset:], w) } offset += thrift.Binary.WriteFieldStop(buf[offset:]) return offset @@ -3597,6 +3626,7 @@ func (p *FieldData) BLength() int { l += p.field1Length() l += p.field2Length() l += p.field3Length() + l += p.field4Length() } l += thrift.Binary.FieldStopLength() return l @@ -3629,6 +3659,15 @@ func (p *FieldData) fastWriteField3(buf []byte, w thrift.NocopyWriter) int { return offset } +func (p *FieldData) fastWriteField4(buf []byte, w thrift.NocopyWriter) int { + offset := 0 + if p.IsSetTraceID() { + offset += thrift.Binary.WriteFieldBegin(buf[offset:], thrift.STRING, 4) + offset += thrift.Binary.WriteStringNocopy(buf[offset:], w, *p.TraceID) + } + return offset +} + func (p *FieldData) field1Length() int { l := 0 if p.IsSetKey() { @@ -3656,6 +3695,15 @@ func (p *FieldData) field3Length() int { return l } +func (p *FieldData) field4Length() int { + l := 0 + if p.IsSetTraceID() { + l += thrift.Binary.FieldBeginLength() + l += thrift.Binary.StringLengthNocopy(*p.TraceID) + } + return l +} + func (p *FieldData) DeepCopy(s interface{}) error { src, ok := s.(*FieldData) if !ok { @@ -3687,5 +3735,13 @@ func (p *FieldData) DeepCopy(s interface{}) error { } p.Content = _content + if src.TraceID != nil { + var tmp string + if *src.TraceID != "" { + tmp = kutils.StringDeepCopy(*src.TraceID) + } + p.TraceID = &tmp + } + return nil } diff --git a/backend/modules/evaluation/application/convertor/evaluation_set/evaluation_set_item.go b/backend/modules/evaluation/application/convertor/evaluation_set/evaluation_set_item.go index 542461687..82120402a 100644 --- a/backend/modules/evaluation/application/convertor/evaluation_set/evaluation_set_item.go +++ b/backend/modules/evaluation/application/convertor/evaluation_set/evaluation_set_item.go @@ -82,6 +82,7 @@ func FieldDataDTO2DO(dto *eval_set.FieldData) *entity.FieldData { Key: gptr.Indirect(dto.Key), Name: gptr.Indirect(dto.Name), Content: common.ConvertContentDTO2DO(dto.Content), + TraceID: gptr.Indirect(dto.TraceID), } } @@ -149,10 +150,11 @@ func FieldDataDO2DTO(do *entity.FieldData) *eval_set.FieldData { if do == nil { return nil } - return &eval_set.FieldData{ + return &eval_set.FieldData { Key: gptr.Of(do.Key), Name: gptr.Of(do.Name), Content: common.ConvertContentDO2DTO(do.Content), + TraceID: gptr.Of(do.TraceID), } } diff --git a/backend/modules/evaluation/domain/entity/evaluation_set_item.go b/backend/modules/evaluation/domain/entity/evaluation_set_item.go index 510c35a5f..5b97754d6 100644 --- a/backend/modules/evaluation/domain/entity/evaluation_set_item.go +++ b/backend/modules/evaluation/domain/entity/evaluation_set_item.go @@ -30,6 +30,7 @@ type FieldData struct { Key string `json:"key,omitempty"` Name string `json:"name,omitempty"` Content *Content `json:"content,omitempty"` + TraceID string `json:"trace_id,omitempty"` } type ItemErrorGroup struct { diff --git a/backend/modules/evaluation/infra/rpc/data/convert.go b/backend/modules/evaluation/infra/rpc/data/convert.go index 1b97de36a..42e4a31cb 100644 --- a/backend/modules/evaluation/infra/rpc/data/convert.go +++ b/backend/modules/evaluation/infra/rpc/data/convert.go @@ -435,6 +435,7 @@ func convert2EvaluationSetFieldData(ctx context.Context, fieldData *dataset.Fiel Video: convertObjectStorageToVideo(ctx, fieldData.Attachments), MultiPart: multiPart, }, + TraceID: gptr.Indirect(fieldData.TraceID), } return evalSetFieldData } diff --git a/idl/thrift/coze/loop/data/domain/dataset.thrift b/idl/thrift/coze/loop/data/domain/dataset.thrift index aa4753745..5a3832c32 100644 --- a/idl/thrift/coze/loop/data/domain/dataset.thrift +++ b/idl/thrift/coze/loop/data/domain/dataset.thrift @@ -233,6 +233,7 @@ struct FieldData { 5: optional list attachments // 外部存储信息 6: optional FieldDisplayFormat format // 数据的渲染格式 7: optional list parts // 图文混排时,图文内容 + 8: optional string trace_id // 关联的 trace ID } struct ObjectStorage { @@ -298,4 +299,4 @@ struct CreateDatasetItemOutput { 2: optional string item_key 3: optional i64 item_id (api.js_conv="true", go.tag='json:"item_id"') 4: optional bool is_new_item // 是否是新的 Item。提供 itemKey 时,如果 itemKey 在数据集中已存在数据,则不算做「新 Item」,该字段为 false。 -} \ No newline at end of file +} diff --git a/idl/thrift/coze/loop/evaluation/domain/eval_set.thrift b/idl/thrift/coze/loop/evaluation/domain/eval_set.thrift index f28980afb..31b7232f2 100644 --- a/idl/thrift/coze/loop/evaluation/domain/eval_set.thrift +++ b/idl/thrift/coze/loop/evaluation/domain/eval_set.thrift @@ -104,6 +104,7 @@ struct FieldData { 1: optional string key, 2: optional string name, 3: optional common.Content content, + 4: optional string trace_id, } From 06ae209c852d4be674952116ed833925d2139ad7 Mon Sep 17 00:00:00 2001 From: "[gaoyichen.16]" <[gaoyichen.16]@bytedance.com> Date: Thu, 5 Feb 2026 20:05:15 +0800 Subject: [PATCH 4/4] style: update format --- .../application/convertor/evaluation_set/evaluation_set_item.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/backend/modules/evaluation/application/convertor/evaluation_set/evaluation_set_item.go b/backend/modules/evaluation/application/convertor/evaluation_set/evaluation_set_item.go index 82120402a..614711a2f 100644 --- a/backend/modules/evaluation/application/convertor/evaluation_set/evaluation_set_item.go +++ b/backend/modules/evaluation/application/convertor/evaluation_set/evaluation_set_item.go @@ -150,7 +150,7 @@ func FieldDataDO2DTO(do *entity.FieldData) *eval_set.FieldData { if do == nil { return nil } - return &eval_set.FieldData { + return &eval_set.FieldData{ Key: gptr.Of(do.Key), Name: gptr.Of(do.Name), Content: common.ConvertContentDO2DTO(do.Content),