l-ai-core-proto/settings.pb.go
2026-07-07 17:09:40 +03:00

637 lines
20 KiB
Go
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

// Code generated by protoc-gen-go. DO NOT EDIT.
// versions:
// protoc-gen-go v1.36.11
// protoc v7.34.0
// source: settings.proto
package proto
import (
protoreflect "google.golang.org/protobuf/reflect/protoreflect"
protoimpl "google.golang.org/protobuf/runtime/protoimpl"
emptypb "google.golang.org/protobuf/types/known/emptypb"
reflect "reflect"
sync "sync"
unsafe "unsafe"
)
const (
// Verify that this generated code is sufficiently up-to-date.
_ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion)
// Verify that runtime/protoimpl is sufficiently up-to-date.
_ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20)
)
type GetPreferredModelRequest struct {
state protoimpl.MessageState `protogen:"open.v1"`
UserId int64 `protobuf:"varint,1,opt,name=user_id,json=userId,proto3" json:"user_id,omitempty"`
unknownFields protoimpl.UnknownFields
sizeCache protoimpl.SizeCache
}
func (x *GetPreferredModelRequest) Reset() {
*x = GetPreferredModelRequest{}
mi := &file_settings_proto_msgTypes[0]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
func (x *GetPreferredModelRequest) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*GetPreferredModelRequest) ProtoMessage() {}
func (x *GetPreferredModelRequest) ProtoReflect() protoreflect.Message {
mi := &file_settings_proto_msgTypes[0]
if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use GetPreferredModelRequest.ProtoReflect.Descriptor instead.
func (*GetPreferredModelRequest) Descriptor() ([]byte, []int) {
return file_settings_proto_rawDescGZIP(), []int{0}
}
func (x *GetPreferredModelRequest) GetUserId() int64 {
if x != nil {
return x.UserId
}
return 0
}
type GetPreferredModelResponse struct {
state protoimpl.MessageState `protogen:"open.v1"`
Model string `protobuf:"bytes,1,opt,name=model,proto3" json:"model,omitempty"`
unknownFields protoimpl.UnknownFields
sizeCache protoimpl.SizeCache
}
func (x *GetPreferredModelResponse) Reset() {
*x = GetPreferredModelResponse{}
mi := &file_settings_proto_msgTypes[1]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
func (x *GetPreferredModelResponse) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*GetPreferredModelResponse) ProtoMessage() {}
func (x *GetPreferredModelResponse) ProtoReflect() protoreflect.Message {
mi := &file_settings_proto_msgTypes[1]
if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use GetPreferredModelResponse.ProtoReflect.Descriptor instead.
func (*GetPreferredModelResponse) Descriptor() ([]byte, []int) {
return file_settings_proto_rawDescGZIP(), []int{1}
}
func (x *GetPreferredModelResponse) GetModel() string {
if x != nil {
return x.Model
}
return ""
}
type SetPreferredModelRequest struct {
state protoimpl.MessageState `protogen:"open.v1"`
UserId int64 `protobuf:"varint,1,opt,name=user_id,json=userId,proto3" json:"user_id,omitempty"`
Username string `protobuf:"bytes,2,opt,name=username,proto3" json:"username,omitempty"`
Model string `protobuf:"bytes,3,opt,name=model,proto3" json:"model,omitempty"`
unknownFields protoimpl.UnknownFields
sizeCache protoimpl.SizeCache
}
func (x *SetPreferredModelRequest) Reset() {
*x = SetPreferredModelRequest{}
mi := &file_settings_proto_msgTypes[2]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
func (x *SetPreferredModelRequest) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*SetPreferredModelRequest) ProtoMessage() {}
func (x *SetPreferredModelRequest) ProtoReflect() protoreflect.Message {
mi := &file_settings_proto_msgTypes[2]
if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use SetPreferredModelRequest.ProtoReflect.Descriptor instead.
func (*SetPreferredModelRequest) Descriptor() ([]byte, []int) {
return file_settings_proto_rawDescGZIP(), []int{2}
}
func (x *SetPreferredModelRequest) GetUserId() int64 {
if x != nil {
return x.UserId
}
return 0
}
func (x *SetPreferredModelRequest) GetUsername() string {
if x != nil {
return x.Username
}
return ""
}
func (x *SetPreferredModelRequest) GetModel() string {
if x != nil {
return x.Model
}
return ""
}
// StylePreset - пресет стиля ответа, хранится в БД
type StylePreset struct {
state protoimpl.MessageState `protogen:"open.v1"`
Id int64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
Name string `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"` // Отображаемое название (например "Токсик")
Prompt string `protobuf:"bytes,3,opt,name=prompt,proto3" json:"prompt,omitempty"` // Текст system prompt
unknownFields protoimpl.UnknownFields
sizeCache protoimpl.SizeCache
}
func (x *StylePreset) Reset() {
*x = StylePreset{}
mi := &file_settings_proto_msgTypes[3]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
func (x *StylePreset) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*StylePreset) ProtoMessage() {}
func (x *StylePreset) ProtoReflect() protoreflect.Message {
mi := &file_settings_proto_msgTypes[3]
if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use StylePreset.ProtoReflect.Descriptor instead.
func (*StylePreset) Descriptor() ([]byte, []int) {
return file_settings_proto_rawDescGZIP(), []int{3}
}
func (x *StylePreset) GetId() int64 {
if x != nil {
return x.Id
}
return 0
}
func (x *StylePreset) GetName() string {
if x != nil {
return x.Name
}
return ""
}
func (x *StylePreset) GetPrompt() string {
if x != nil {
return x.Prompt
}
return ""
}
type ListStylePresetsRequest struct {
state protoimpl.MessageState `protogen:"open.v1"`
unknownFields protoimpl.UnknownFields
sizeCache protoimpl.SizeCache
}
func (x *ListStylePresetsRequest) Reset() {
*x = ListStylePresetsRequest{}
mi := &file_settings_proto_msgTypes[4]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
func (x *ListStylePresetsRequest) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*ListStylePresetsRequest) ProtoMessage() {}
func (x *ListStylePresetsRequest) ProtoReflect() protoreflect.Message {
mi := &file_settings_proto_msgTypes[4]
if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use ListStylePresetsRequest.ProtoReflect.Descriptor instead.
func (*ListStylePresetsRequest) Descriptor() ([]byte, []int) {
return file_settings_proto_rawDescGZIP(), []int{4}
}
type ListStylePresetsResponse struct {
state protoimpl.MessageState `protogen:"open.v1"`
Presets []*StylePreset `protobuf:"bytes,1,rep,name=presets,proto3" json:"presets,omitempty"`
unknownFields protoimpl.UnknownFields
sizeCache protoimpl.SizeCache
}
func (x *ListStylePresetsResponse) Reset() {
*x = ListStylePresetsResponse{}
mi := &file_settings_proto_msgTypes[5]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
func (x *ListStylePresetsResponse) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*ListStylePresetsResponse) ProtoMessage() {}
func (x *ListStylePresetsResponse) ProtoReflect() protoreflect.Message {
mi := &file_settings_proto_msgTypes[5]
if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use ListStylePresetsResponse.ProtoReflect.Descriptor instead.
func (*ListStylePresetsResponse) Descriptor() ([]byte, []int) {
return file_settings_proto_rawDescGZIP(), []int{5}
}
func (x *ListStylePresetsResponse) GetPresets() []*StylePreset {
if x != nil {
return x.Presets
}
return nil
}
type GetUserStyleRequest struct {
state protoimpl.MessageState `protogen:"open.v1"`
UserId int64 `protobuf:"varint,1,opt,name=user_id,json=userId,proto3" json:"user_id,omitempty"` // Telegram user ID
unknownFields protoimpl.UnknownFields
sizeCache protoimpl.SizeCache
}
func (x *GetUserStyleRequest) Reset() {
*x = GetUserStyleRequest{}
mi := &file_settings_proto_msgTypes[6]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
func (x *GetUserStyleRequest) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*GetUserStyleRequest) ProtoMessage() {}
func (x *GetUserStyleRequest) ProtoReflect() protoreflect.Message {
mi := &file_settings_proto_msgTypes[6]
if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use GetUserStyleRequest.ProtoReflect.Descriptor instead.
func (*GetUserStyleRequest) Descriptor() ([]byte, []int) {
return file_settings_proto_rawDescGZIP(), []int{6}
}
func (x *GetUserStyleRequest) GetUserId() int64 {
if x != nil {
return x.UserId
}
return 0
}
type GetUserStyleResponse struct {
state protoimpl.MessageState `protogen:"open.v1"`
PresetId int64 `protobuf:"varint,1,opt,name=preset_id,json=presetId,proto3" json:"preset_id,omitempty"` // ID выбранного пресета (0 - не выбран)
CustomPrompt string `protobuf:"bytes,2,opt,name=custom_prompt,json=customPrompt,proto3" json:"custom_prompt,omitempty"` // Кастомный промпт (пустой - не задан)
unknownFields protoimpl.UnknownFields
sizeCache protoimpl.SizeCache
}
func (x *GetUserStyleResponse) Reset() {
*x = GetUserStyleResponse{}
mi := &file_settings_proto_msgTypes[7]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
func (x *GetUserStyleResponse) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*GetUserStyleResponse) ProtoMessage() {}
func (x *GetUserStyleResponse) ProtoReflect() protoreflect.Message {
mi := &file_settings_proto_msgTypes[7]
if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use GetUserStyleResponse.ProtoReflect.Descriptor instead.
func (*GetUserStyleResponse) Descriptor() ([]byte, []int) {
return file_settings_proto_rawDescGZIP(), []int{7}
}
func (x *GetUserStyleResponse) GetPresetId() int64 {
if x != nil {
return x.PresetId
}
return 0
}
func (x *GetUserStyleResponse) GetCustomPrompt() string {
if x != nil {
return x.CustomPrompt
}
return ""
}
type SetUserStyleRequest struct {
state protoimpl.MessageState `protogen:"open.v1"`
UserId int64 `protobuf:"varint,1,opt,name=user_id,json=userId,proto3" json:"user_id,omitempty"` // Telegram user ID
Username string `protobuf:"bytes,2,opt,name=username,proto3" json:"username,omitempty"`
// Выбор стиля: пресет, кастомный промпт или сброс на дефолт
//
// Types that are valid to be assigned to Style:
//
// *SetUserStyleRequest_PresetId
// *SetUserStyleRequest_CustomPrompt
// *SetUserStyleRequest_Reset_
Style isSetUserStyleRequest_Style `protobuf_oneof:"style"`
unknownFields protoimpl.UnknownFields
sizeCache protoimpl.SizeCache
}
func (x *SetUserStyleRequest) Reset() {
*x = SetUserStyleRequest{}
mi := &file_settings_proto_msgTypes[8]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
func (x *SetUserStyleRequest) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*SetUserStyleRequest) ProtoMessage() {}
func (x *SetUserStyleRequest) ProtoReflect() protoreflect.Message {
mi := &file_settings_proto_msgTypes[8]
if x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use SetUserStyleRequest.ProtoReflect.Descriptor instead.
func (*SetUserStyleRequest) Descriptor() ([]byte, []int) {
return file_settings_proto_rawDescGZIP(), []int{8}
}
func (x *SetUserStyleRequest) GetUserId() int64 {
if x != nil {
return x.UserId
}
return 0
}
func (x *SetUserStyleRequest) GetUsername() string {
if x != nil {
return x.Username
}
return ""
}
func (x *SetUserStyleRequest) GetStyle() isSetUserStyleRequest_Style {
if x != nil {
return x.Style
}
return nil
}
func (x *SetUserStyleRequest) GetPresetId() int64 {
if x != nil {
if x, ok := x.Style.(*SetUserStyleRequest_PresetId); ok {
return x.PresetId
}
}
return 0
}
func (x *SetUserStyleRequest) GetCustomPrompt() string {
if x != nil {
if x, ok := x.Style.(*SetUserStyleRequest_CustomPrompt); ok {
return x.CustomPrompt
}
}
return ""
}
func (x *SetUserStyleRequest) GetReset_() bool {
if x != nil {
if x, ok := x.Style.(*SetUserStyleRequest_Reset_); ok {
return x.Reset_
}
}
return false
}
type isSetUserStyleRequest_Style interface {
isSetUserStyleRequest_Style()
}
type SetUserStyleRequest_PresetId struct {
PresetId int64 `protobuf:"varint,3,opt,name=preset_id,json=presetId,proto3,oneof"` // Выбрать пресет по ID
}
type SetUserStyleRequest_CustomPrompt struct {
CustomPrompt string `protobuf:"bytes,4,opt,name=custom_prompt,json=customPrompt,proto3,oneof"` // Задать свой промпт (макс 4000 символов)
}
type SetUserStyleRequest_Reset_ struct {
Reset_ bool `protobuf:"varint,5,opt,name=reset,proto3,oneof"` // Сбросить стиль на дефолтный
}
func (*SetUserStyleRequest_PresetId) isSetUserStyleRequest_Style() {}
func (*SetUserStyleRequest_CustomPrompt) isSetUserStyleRequest_Style() {}
func (*SetUserStyleRequest_Reset_) isSetUserStyleRequest_Style() {}
var File_settings_proto protoreflect.FileDescriptor
const file_settings_proto_rawDesc = "" +
"\n" +
"\x0esettings.proto\x12\x05users\x1a\x1bgoogle/protobuf/empty.proto\"3\n" +
"\x18GetPreferredModelRequest\x12\x17\n" +
"\auser_id\x18\x01 \x01(\x03R\x06userId\"1\n" +
"\x19GetPreferredModelResponse\x12\x14\n" +
"\x05model\x18\x01 \x01(\tR\x05model\"e\n" +
"\x18SetPreferredModelRequest\x12\x17\n" +
"\auser_id\x18\x01 \x01(\x03R\x06userId\x12\x1a\n" +
"\busername\x18\x02 \x01(\tR\busername\x12\x14\n" +
"\x05model\x18\x03 \x01(\tR\x05model\"I\n" +
"\vStylePreset\x12\x0e\n" +
"\x02id\x18\x01 \x01(\x03R\x02id\x12\x12\n" +
"\x04name\x18\x02 \x01(\tR\x04name\x12\x16\n" +
"\x06prompt\x18\x03 \x01(\tR\x06prompt\"\x19\n" +
"\x17ListStylePresetsRequest\"H\n" +
"\x18ListStylePresetsResponse\x12,\n" +
"\apresets\x18\x01 \x03(\v2\x12.users.StylePresetR\apresets\".\n" +
"\x13GetUserStyleRequest\x12\x17\n" +
"\auser_id\x18\x01 \x01(\x03R\x06userId\"X\n" +
"\x14GetUserStyleResponse\x12\x1b\n" +
"\tpreset_id\x18\x01 \x01(\x03R\bpresetId\x12#\n" +
"\rcustom_prompt\x18\x02 \x01(\tR\fcustomPrompt\"\xb1\x01\n" +
"\x13SetUserStyleRequest\x12\x17\n" +
"\auser_id\x18\x01 \x01(\x03R\x06userId\x12\x1a\n" +
"\busername\x18\x02 \x01(\tR\busername\x12\x1d\n" +
"\tpreset_id\x18\x03 \x01(\x03H\x00R\bpresetId\x12%\n" +
"\rcustom_prompt\x18\x04 \x01(\tH\x00R\fcustomPrompt\x12\x16\n" +
"\x05reset\x18\x05 \x01(\bH\x00R\x05resetB\a\n" +
"\x05style2\x9d\x03\n" +
"\x13UserSettingsService\x12V\n" +
"\x11GetPreferredModel\x12\x1f.users.GetPreferredModelRequest\x1a .users.GetPreferredModelResponse\x12L\n" +
"\x11SetPreferredModel\x12\x1f.users.SetPreferredModelRequest\x1a\x16.google.protobuf.Empty\x12S\n" +
"\x10ListStylePresets\x12\x1e.users.ListStylePresetsRequest\x1a\x1f.users.ListStylePresetsResponse\x12G\n" +
"\fGetUserStyle\x12\x1a.users.GetUserStyleRequest\x1a\x1b.users.GetUserStyleResponse\x12B\n" +
"\fSetUserStyle\x12\x1a.users.SetUserStyleRequest\x1a\x16.google.protobuf.EmptyB,Z*git.be.kaien.ru/l-ai/l-ai-core-proto/protob\x06proto3"
var (
file_settings_proto_rawDescOnce sync.Once
file_settings_proto_rawDescData []byte
)
func file_settings_proto_rawDescGZIP() []byte {
file_settings_proto_rawDescOnce.Do(func() {
file_settings_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_settings_proto_rawDesc), len(file_settings_proto_rawDesc)))
})
return file_settings_proto_rawDescData
}
var file_settings_proto_msgTypes = make([]protoimpl.MessageInfo, 9)
var file_settings_proto_goTypes = []any{
(*GetPreferredModelRequest)(nil), // 0: users.GetPreferredModelRequest
(*GetPreferredModelResponse)(nil), // 1: users.GetPreferredModelResponse
(*SetPreferredModelRequest)(nil), // 2: users.SetPreferredModelRequest
(*StylePreset)(nil), // 3: users.StylePreset
(*ListStylePresetsRequest)(nil), // 4: users.ListStylePresetsRequest
(*ListStylePresetsResponse)(nil), // 5: users.ListStylePresetsResponse
(*GetUserStyleRequest)(nil), // 6: users.GetUserStyleRequest
(*GetUserStyleResponse)(nil), // 7: users.GetUserStyleResponse
(*SetUserStyleRequest)(nil), // 8: users.SetUserStyleRequest
(*emptypb.Empty)(nil), // 9: google.protobuf.Empty
}
var file_settings_proto_depIdxs = []int32{
3, // 0: users.ListStylePresetsResponse.presets:type_name -> users.StylePreset
0, // 1: users.UserSettingsService.GetPreferredModel:input_type -> users.GetPreferredModelRequest
2, // 2: users.UserSettingsService.SetPreferredModel:input_type -> users.SetPreferredModelRequest
4, // 3: users.UserSettingsService.ListStylePresets:input_type -> users.ListStylePresetsRequest
6, // 4: users.UserSettingsService.GetUserStyle:input_type -> users.GetUserStyleRequest
8, // 5: users.UserSettingsService.SetUserStyle:input_type -> users.SetUserStyleRequest
1, // 6: users.UserSettingsService.GetPreferredModel:output_type -> users.GetPreferredModelResponse
9, // 7: users.UserSettingsService.SetPreferredModel:output_type -> google.protobuf.Empty
5, // 8: users.UserSettingsService.ListStylePresets:output_type -> users.ListStylePresetsResponse
7, // 9: users.UserSettingsService.GetUserStyle:output_type -> users.GetUserStyleResponse
9, // 10: users.UserSettingsService.SetUserStyle:output_type -> google.protobuf.Empty
6, // [6:11] is the sub-list for method output_type
1, // [1:6] is the sub-list for method input_type
1, // [1:1] is the sub-list for extension type_name
1, // [1:1] is the sub-list for extension extendee
0, // [0:1] is the sub-list for field type_name
}
func init() { file_settings_proto_init() }
func file_settings_proto_init() {
if File_settings_proto != nil {
return
}
file_settings_proto_msgTypes[8].OneofWrappers = []any{
(*SetUserStyleRequest_PresetId)(nil),
(*SetUserStyleRequest_CustomPrompt)(nil),
(*SetUserStyleRequest_Reset_)(nil),
}
type x struct{}
out := protoimpl.TypeBuilder{
File: protoimpl.DescBuilder{
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
RawDescriptor: unsafe.Slice(unsafe.StringData(file_settings_proto_rawDesc), len(file_settings_proto_rawDesc)),
NumEnums: 0,
NumMessages: 9,
NumExtensions: 0,
NumServices: 1,
},
GoTypes: file_settings_proto_goTypes,
DependencyIndexes: file_settings_proto_depIdxs,
MessageInfos: file_settings_proto_msgTypes,
}.Build()
File_settings_proto = out.File
file_settings_proto_goTypes = nil
file_settings_proto_depIdxs = nil
}