* feat(retain): add verbatim extraction mode Adds retain_extraction_mode="verbatim" that stores each chunk as-is without LLM summarization. The LLM still runs to extract entities, temporal info, and location for full indexability — only the fact text is replaced with the original chunk content (one memory per chunk). Useful for RAG-style indexing and benchmarks where original text must be preserved in memory. - Add "verbatim" to RETAIN_EXTRACTION_MODES in config.py - Add VERBATIM_FACT_EXTRACTION_PROMPT with instructions to preserve text - Add _collapse_to_verbatim() post-processing to enforce 1 fact/chunk - Expose in bank config UI dropdown with updated description - Update configuration.md docs with verbatim mode description - Add unit test for _collapse_to_verbatim and integration test via LLM - Fix pre-existing main.py CLI override missing new reranker fields - Fix pre-existing cross_encoder.py ty type error via setattr * refactor(retain): verbatim mode skips 'what' field entirely Instead of asking the LLM to echo the chunk text back into 'what' and then discarding it, verbatim mode now uses a dedicated schema (VerbatimExtractedFact) that omits the 'what' field altogether. The LLM only returns metadata (entities, temporal info, location, who), saving output tokens and avoiding any risk of paraphrasing before the backfill. - Add VerbatimExtractedFact / VerbatimFactExtractionResponse models - Verbatim mode skips causal-relations section (nothing to relate causally) - _extract_facts_from_chunk: allow missing 'what' in verbatim mode, set combined_text="" (backfilled by _collapse_to_verbatim) - Update verbatim prompt to say DO NOT include 'what' * feat(retain): add index_only extraction mode Zero-LLM retain mode: chunks are stored as-is with no LLM call, no entity extraction, and no temporal indexing. Embeddings still run for semantic search. User-provided entities via RetainContent.entities are the sole source of entity data. Early return placed before the batch-API check so no LLM queue or concurrency locks are acquired. - Add "index_only" to RETAIN_EXTRACTION_MODES - Add _extract_facts_index_only() with pure Python chunking path - Add to UI dropdown and update description - Update configuration.md with index_only docs and table entry - Add unit test asserting zero token usage and exact text preservation * feat(retain): add named retain strategies Allows mixing extraction modes in a single bank via named strategies. Each strategy is a set of hierarchical config overrides (extraction_mode, chunk_size, entity_labels, entities_allow_free_form, etc.) applied on top of the resolved bank config at retain time. - retain_strategies: dict of strategy_name → config overrides (bank config) - retain_default_strategy: default strategy when none specified (bank config) - strategy field on /retain request: per-call override - apply_strategy() in config_resolver applies overrides via dataclasses.replace() - strategy propagates through retain_batch_async → _retain_batch_async_internal and through the async worker task payload - Any hierarchical field is overridable per strategy, including entity_labels and entities_allow_free_form - Docs updated with strategy configuration example and RRF fairness note - Unit test for apply_strategy covering overrides, unknown strategy, and non-hierarchical field filtering * feat(retain): add per-item strategy and strategy tests - Add `strategy` field to `MemoryItem` so individual items in a retain request can override the request-level strategy - Add `strategy` field to `FileRetainMetadata` for per-file strategy override in file retain requests - Group memory items by effective strategy in `api_retain`; each group is processed as a separate batch, results are aggregated - Thread strategy through `submit_async_file_retain` → `_handle_file_convert_retain` → retain task payload - Add `operation_ids` to `RetainResponse` for async requests with mixed per-item strategies - Add `test_strategy_overrides_extraction_mode_for_index_only`: unit test verifying a named strategy with index_only bypasses the LLM - Add `test_retain_request_per_item_strategy_field`: unit test for per-item strategy grouping logic * feat(ui): add retain strategies and default strategy to bank config UI - Add StrategiesEditor component: per-strategy cards with name input and JSON overrides textarea; supports add/remove; validates JSON inline - Add Default Strategy text input (retain_default_strategy) - Update RetainEdits type and retainSlice() to include both new fields - Regenerate OpenAPI spec (retain_strategies, retain_default_strategy, per-item strategy on MemoryItem/FileRetainMetadata, operation_ids on RetainResponse) * refactor(ui): move retain strategies into its own dedicated config section * feat(ui): improve retain strategies UX and add strategy to document dialog - Strategy form now includes entity section (free form toggle + entity labels editor) - Default strategy selector moved outside tab panel, above strategy chips - Strategy tabs redesigned with underline indicator style for clarity - Remove strategy confirms with AlertDialog - Fix tab re-render bug when typing strategy name (skipSyncRef) - Add strategy field to Add New Document dialog (text + per-file for uploads) - File upload collapsible uses same Document/Tags/Source tabbed layout - API: validate empty strategy names in config_resolver - api.ts: add strategy field to retain and uploadFiles types * fix: forward strategy through HTTP layer and SDK; add integration test - route.ts: extract and forward `strategy` from request body to retainBatch - TypeScript SDK: accept and forward `strategy` in retainBatch options and per-item - config_resolver.py: validate empty strategy name keys on update - bank-config-view.tsx: merge entity fields into RetainStrategyForm, redesign strategy tabs with underline style, add confirmation dialog for removal, fix tab-reset-on-typing with skipSyncRef, move default strategy selector outside panel - bank-selector.tsx: add strategy field to Add Document dialog (per-file in tabbed collapsible) - test_retain.py: add end-to-end integration test verifying named strategy application (index_only = 0 LLM tokens) * fix: regenerate TypeScript client with strategy field in RetainRequest/MemoryItem - Regenerate OpenAPI spec to include strategy field in RetainRequest and MemoryItem - Regenerate TypeScript client from updated spec - Add strategy to MemoryItemInput interface - Remove (item as any) cast now that strategy is properly typed * rename: index_only extraction mode → chunks * remove top-level strategy from RetainRequest; strategy is per-item only * fix(clients): update Go and Python generated clients with strategy/operation_ids fields * fix(ci): update hierarchical field count, add strategy to Rust MemoryItem initializers * fix(go-client): minimal targeted YAML updates for strategy/operation_ids fields
499 lines
14 KiB
Go
499 lines
14 KiB
Go
/*
|
|
Hindsight HTTP API
|
|
|
|
HTTP API for Hindsight
|
|
|
|
API version: 0.4.18
|
|
*/
|
|
|
|
// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT.
|
|
|
|
package hindsight
|
|
|
|
import (
|
|
"encoding/json"
|
|
"bytes"
|
|
"fmt"
|
|
)
|
|
|
|
// checks if the MemoryItem type satisfies the MappedNullable interface at compile time
|
|
var _ MappedNullable = &MemoryItem{}
|
|
|
|
// MemoryItem Single memory item for retain.
|
|
type MemoryItem struct {
|
|
Content string `json:"content"`
|
|
Timestamp NullableTimestamp `json:"timestamp,omitempty"`
|
|
Context NullableString `json:"context,omitempty"`
|
|
Metadata map[string]string `json:"metadata,omitempty"`
|
|
DocumentId NullableString `json:"document_id,omitempty"`
|
|
Entities []EntityInput `json:"entities,omitempty"`
|
|
Tags []string `json:"tags,omitempty"`
|
|
ObservationScopes NullableObservationScopes `json:"observation_scopes,omitempty"`
|
|
Strategy NullableString `json:"strategy,omitempty"`
|
|
}
|
|
|
|
type _MemoryItem MemoryItem
|
|
|
|
// NewMemoryItem instantiates a new MemoryItem object
|
|
// This constructor will assign default values to properties that have it defined,
|
|
// and makes sure properties required by API are set, but the set of arguments
|
|
// will change when the set of required properties is changed
|
|
func NewMemoryItem(content string) *MemoryItem {
|
|
this := MemoryItem{}
|
|
this.Content = content
|
|
return &this
|
|
}
|
|
|
|
// NewMemoryItemWithDefaults instantiates a new MemoryItem object
|
|
// This constructor will only assign default values to properties that have it defined,
|
|
// but it doesn't guarantee that properties required by API are set
|
|
func NewMemoryItemWithDefaults() *MemoryItem {
|
|
this := MemoryItem{}
|
|
return &this
|
|
}
|
|
|
|
// GetContent returns the Content field value
|
|
func (o *MemoryItem) GetContent() string {
|
|
if o == nil {
|
|
var ret string
|
|
return ret
|
|
}
|
|
|
|
return o.Content
|
|
}
|
|
|
|
// GetContentOk returns a tuple with the Content field value
|
|
// and a boolean to check if the value has been set.
|
|
func (o *MemoryItem) GetContentOk() (*string, bool) {
|
|
if o == nil {
|
|
return nil, false
|
|
}
|
|
return &o.Content, true
|
|
}
|
|
|
|
// SetContent sets field value
|
|
func (o *MemoryItem) SetContent(v string) {
|
|
o.Content = v
|
|
}
|
|
|
|
// GetTimestamp returns the Timestamp field value if set, zero value otherwise (both if not set or set to explicit null).
|
|
func (o *MemoryItem) GetTimestamp() Timestamp {
|
|
if o == nil || IsNil(o.Timestamp.Get()) {
|
|
var ret Timestamp
|
|
return ret
|
|
}
|
|
return *o.Timestamp.Get()
|
|
}
|
|
|
|
// GetTimestampOk returns a tuple with the Timestamp field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
// NOTE: If the value is an explicit nil, `nil, true` will be returned
|
|
func (o *MemoryItem) GetTimestampOk() (*Timestamp, bool) {
|
|
if o == nil {
|
|
return nil, false
|
|
}
|
|
return o.Timestamp.Get(), o.Timestamp.IsSet()
|
|
}
|
|
|
|
// HasTimestamp returns a boolean if a field has been set.
|
|
func (o *MemoryItem) HasTimestamp() bool {
|
|
if o != nil && o.Timestamp.IsSet() {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetTimestamp gets a reference to the given NullableTimestamp and assigns it to the Timestamp field.
|
|
func (o *MemoryItem) SetTimestamp(v Timestamp) {
|
|
o.Timestamp.Set(&v)
|
|
}
|
|
// SetTimestampNil sets the value for Timestamp to be an explicit nil
|
|
func (o *MemoryItem) SetTimestampNil() {
|
|
o.Timestamp.Set(nil)
|
|
}
|
|
|
|
// UnsetTimestamp ensures that no value is present for Timestamp, not even an explicit nil
|
|
func (o *MemoryItem) UnsetTimestamp() {
|
|
o.Timestamp.Unset()
|
|
}
|
|
|
|
// GetContext returns the Context field value if set, zero value otherwise (both if not set or set to explicit null).
|
|
func (o *MemoryItem) GetContext() string {
|
|
if o == nil || IsNil(o.Context.Get()) {
|
|
var ret string
|
|
return ret
|
|
}
|
|
return *o.Context.Get()
|
|
}
|
|
|
|
// GetContextOk returns a tuple with the Context field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
// NOTE: If the value is an explicit nil, `nil, true` will be returned
|
|
func (o *MemoryItem) GetContextOk() (*string, bool) {
|
|
if o == nil {
|
|
return nil, false
|
|
}
|
|
return o.Context.Get(), o.Context.IsSet()
|
|
}
|
|
|
|
// HasContext returns a boolean if a field has been set.
|
|
func (o *MemoryItem) HasContext() bool {
|
|
if o != nil && o.Context.IsSet() {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetContext gets a reference to the given NullableString and assigns it to the Context field.
|
|
func (o *MemoryItem) SetContext(v string) {
|
|
o.Context.Set(&v)
|
|
}
|
|
// SetContextNil sets the value for Context to be an explicit nil
|
|
func (o *MemoryItem) SetContextNil() {
|
|
o.Context.Set(nil)
|
|
}
|
|
|
|
// UnsetContext ensures that no value is present for Context, not even an explicit nil
|
|
func (o *MemoryItem) UnsetContext() {
|
|
o.Context.Unset()
|
|
}
|
|
|
|
// GetMetadata returns the Metadata field value if set, zero value otherwise (both if not set or set to explicit null).
|
|
func (o *MemoryItem) GetMetadata() map[string]string {
|
|
if o == nil {
|
|
var ret map[string]string
|
|
return ret
|
|
}
|
|
return o.Metadata
|
|
}
|
|
|
|
// GetMetadataOk returns a tuple with the Metadata field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
// NOTE: If the value is an explicit nil, `nil, true` will be returned
|
|
func (o *MemoryItem) GetMetadataOk() (map[string]string, bool) {
|
|
if o == nil || IsNil(o.Metadata) {
|
|
return map[string]string{}, false
|
|
}
|
|
return o.Metadata, true
|
|
}
|
|
|
|
// HasMetadata returns a boolean if a field has been set.
|
|
func (o *MemoryItem) HasMetadata() bool {
|
|
if o != nil && !IsNil(o.Metadata) {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetMetadata gets a reference to the given map[string]string and assigns it to the Metadata field.
|
|
func (o *MemoryItem) SetMetadata(v map[string]string) {
|
|
o.Metadata = v
|
|
}
|
|
|
|
// GetDocumentId returns the DocumentId field value if set, zero value otherwise (both if not set or set to explicit null).
|
|
func (o *MemoryItem) GetDocumentId() string {
|
|
if o == nil || IsNil(o.DocumentId.Get()) {
|
|
var ret string
|
|
return ret
|
|
}
|
|
return *o.DocumentId.Get()
|
|
}
|
|
|
|
// GetDocumentIdOk returns a tuple with the DocumentId field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
// NOTE: If the value is an explicit nil, `nil, true` will be returned
|
|
func (o *MemoryItem) GetDocumentIdOk() (*string, bool) {
|
|
if o == nil {
|
|
return nil, false
|
|
}
|
|
return o.DocumentId.Get(), o.DocumentId.IsSet()
|
|
}
|
|
|
|
// HasDocumentId returns a boolean if a field has been set.
|
|
func (o *MemoryItem) HasDocumentId() bool {
|
|
if o != nil && o.DocumentId.IsSet() {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetDocumentId gets a reference to the given NullableString and assigns it to the DocumentId field.
|
|
func (o *MemoryItem) SetDocumentId(v string) {
|
|
o.DocumentId.Set(&v)
|
|
}
|
|
// SetDocumentIdNil sets the value for DocumentId to be an explicit nil
|
|
func (o *MemoryItem) SetDocumentIdNil() {
|
|
o.DocumentId.Set(nil)
|
|
}
|
|
|
|
// UnsetDocumentId ensures that no value is present for DocumentId, not even an explicit nil
|
|
func (o *MemoryItem) UnsetDocumentId() {
|
|
o.DocumentId.Unset()
|
|
}
|
|
|
|
// GetEntities returns the Entities field value if set, zero value otherwise (both if not set or set to explicit null).
|
|
func (o *MemoryItem) GetEntities() []EntityInput {
|
|
if o == nil {
|
|
var ret []EntityInput
|
|
return ret
|
|
}
|
|
return o.Entities
|
|
}
|
|
|
|
// GetEntitiesOk returns a tuple with the Entities field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
// NOTE: If the value is an explicit nil, `nil, true` will be returned
|
|
func (o *MemoryItem) GetEntitiesOk() ([]EntityInput, bool) {
|
|
if o == nil || IsNil(o.Entities) {
|
|
return nil, false
|
|
}
|
|
return o.Entities, true
|
|
}
|
|
|
|
// HasEntities returns a boolean if a field has been set.
|
|
func (o *MemoryItem) HasEntities() bool {
|
|
if o != nil && !IsNil(o.Entities) {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetEntities gets a reference to the given []EntityInput and assigns it to the Entities field.
|
|
func (o *MemoryItem) SetEntities(v []EntityInput) {
|
|
o.Entities = v
|
|
}
|
|
|
|
// GetTags returns the Tags field value if set, zero value otherwise (both if not set or set to explicit null).
|
|
func (o *MemoryItem) GetTags() []string {
|
|
if o == nil {
|
|
var ret []string
|
|
return ret
|
|
}
|
|
return o.Tags
|
|
}
|
|
|
|
// GetTagsOk returns a tuple with the Tags field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
// NOTE: If the value is an explicit nil, `nil, true` will be returned
|
|
func (o *MemoryItem) GetTagsOk() ([]string, bool) {
|
|
if o == nil || IsNil(o.Tags) {
|
|
return nil, false
|
|
}
|
|
return o.Tags, true
|
|
}
|
|
|
|
// HasTags returns a boolean if a field has been set.
|
|
func (o *MemoryItem) HasTags() bool {
|
|
if o != nil && !IsNil(o.Tags) {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetTags gets a reference to the given []string and assigns it to the Tags field.
|
|
func (o *MemoryItem) SetTags(v []string) {
|
|
o.Tags = v
|
|
}
|
|
|
|
// GetObservationScopes returns the ObservationScopes field value if set, zero value otherwise (both if not set or set to explicit null).
|
|
func (o *MemoryItem) GetObservationScopes() ObservationScopes {
|
|
if o == nil || IsNil(o.ObservationScopes.Get()) {
|
|
var ret ObservationScopes
|
|
return ret
|
|
}
|
|
return *o.ObservationScopes.Get()
|
|
}
|
|
|
|
// GetObservationScopesOk returns a tuple with the ObservationScopes field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
// NOTE: If the value is an explicit nil, `nil, true` will be returned
|
|
func (o *MemoryItem) GetObservationScopesOk() (*ObservationScopes, bool) {
|
|
if o == nil {
|
|
return nil, false
|
|
}
|
|
return o.ObservationScopes.Get(), o.ObservationScopes.IsSet()
|
|
}
|
|
|
|
// HasObservationScopes returns a boolean if a field has been set.
|
|
func (o *MemoryItem) HasObservationScopes() bool {
|
|
if o != nil && o.ObservationScopes.IsSet() {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetObservationScopes gets a reference to the given NullableObservationScopes and assigns it to the ObservationScopes field.
|
|
func (o *MemoryItem) SetObservationScopes(v ObservationScopes) {
|
|
o.ObservationScopes.Set(&v)
|
|
}
|
|
// SetObservationScopesNil sets the value for ObservationScopes to be an explicit nil
|
|
func (o *MemoryItem) SetObservationScopesNil() {
|
|
o.ObservationScopes.Set(nil)
|
|
}
|
|
|
|
// UnsetObservationScopes ensures that no value is present for ObservationScopes, not even an explicit nil
|
|
func (o *MemoryItem) UnsetObservationScopes() {
|
|
o.ObservationScopes.Unset()
|
|
}
|
|
|
|
// GetStrategy returns the Strategy field value if set, zero value otherwise (both if not set or set to explicit null).
|
|
func (o *MemoryItem) GetStrategy() string {
|
|
if o == nil || IsNil(o.Strategy.Get()) {
|
|
var ret string
|
|
return ret
|
|
}
|
|
return *o.Strategy.Get()
|
|
}
|
|
|
|
// GetStrategyOk returns a tuple with the Strategy field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
// NOTE: If the value is an explicit nil, `nil, true` will be returned
|
|
func (o *MemoryItem) GetStrategyOk() (*string, bool) {
|
|
if o == nil {
|
|
return nil, false
|
|
}
|
|
return o.Strategy.Get(), o.Strategy.IsSet()
|
|
}
|
|
|
|
// HasStrategy returns a boolean if a field has been set.
|
|
func (o *MemoryItem) HasStrategy() bool {
|
|
if o != nil && o.Strategy.IsSet() {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetStrategy gets a reference to the given NullableString and assigns it to the Strategy field.
|
|
func (o *MemoryItem) SetStrategy(v string) {
|
|
o.Strategy.Set(&v)
|
|
}
|
|
// SetStrategyNil sets the value for Strategy to be an explicit nil
|
|
func (o *MemoryItem) SetStrategyNil() {
|
|
o.Strategy.Set(nil)
|
|
}
|
|
|
|
// UnsetStrategy ensures that no value is present for Strategy, not even an explicit nil
|
|
func (o *MemoryItem) UnsetStrategy() {
|
|
o.Strategy.Unset()
|
|
}
|
|
|
|
func (o MemoryItem) MarshalJSON() ([]byte, error) {
|
|
toSerialize,err := o.ToMap()
|
|
if err != nil {
|
|
return []byte{}, err
|
|
}
|
|
return json.Marshal(toSerialize)
|
|
}
|
|
|
|
func (o MemoryItem) ToMap() (map[string]interface{}, error) {
|
|
toSerialize := map[string]interface{}{}
|
|
toSerialize["content"] = o.Content
|
|
if o.Timestamp.IsSet() {
|
|
toSerialize["timestamp"] = o.Timestamp.Get()
|
|
}
|
|
if o.Context.IsSet() {
|
|
toSerialize["context"] = o.Context.Get()
|
|
}
|
|
if o.Metadata != nil {
|
|
toSerialize["metadata"] = o.Metadata
|
|
}
|
|
if o.DocumentId.IsSet() {
|
|
toSerialize["document_id"] = o.DocumentId.Get()
|
|
}
|
|
if o.Entities != nil {
|
|
toSerialize["entities"] = o.Entities
|
|
}
|
|
if o.Tags != nil {
|
|
toSerialize["tags"] = o.Tags
|
|
}
|
|
if o.ObservationScopes.IsSet() {
|
|
toSerialize["observation_scopes"] = o.ObservationScopes.Get()
|
|
}
|
|
if o.Strategy.IsSet() {
|
|
toSerialize["strategy"] = o.Strategy.Get()
|
|
}
|
|
return toSerialize, nil
|
|
}
|
|
|
|
func (o *MemoryItem) UnmarshalJSON(data []byte) (err error) {
|
|
// This validates that all required properties are included in the JSON object
|
|
// by unmarshalling the object into a generic map with string keys and checking
|
|
// that every required field exists as a key in the generic map.
|
|
requiredProperties := []string{
|
|
"content",
|
|
}
|
|
|
|
allProperties := make(map[string]interface{})
|
|
|
|
err = json.Unmarshal(data, &allProperties)
|
|
|
|
if err != nil {
|
|
return err;
|
|
}
|
|
|
|
for _, requiredProperty := range(requiredProperties) {
|
|
if _, exists := allProperties[requiredProperty]; !exists {
|
|
return fmt.Errorf("no value given for required property %v", requiredProperty)
|
|
}
|
|
}
|
|
|
|
varMemoryItem := _MemoryItem{}
|
|
|
|
decoder := json.NewDecoder(bytes.NewReader(data))
|
|
decoder.DisallowUnknownFields()
|
|
err = decoder.Decode(&varMemoryItem)
|
|
|
|
if err != nil {
|
|
return err
|
|
}
|
|
|
|
*o = MemoryItem(varMemoryItem)
|
|
|
|
return err
|
|
}
|
|
|
|
type NullableMemoryItem struct {
|
|
value *MemoryItem
|
|
isSet bool
|
|
}
|
|
|
|
func (v NullableMemoryItem) Get() *MemoryItem {
|
|
return v.value
|
|
}
|
|
|
|
func (v *NullableMemoryItem) Set(val *MemoryItem) {
|
|
v.value = val
|
|
v.isSet = true
|
|
}
|
|
|
|
func (v NullableMemoryItem) IsSet() bool {
|
|
return v.isSet
|
|
}
|
|
|
|
func (v *NullableMemoryItem) Unset() {
|
|
v.value = nil
|
|
v.isSet = false
|
|
}
|
|
|
|
func NewNullableMemoryItem(val *MemoryItem) *NullableMemoryItem {
|
|
return &NullableMemoryItem{value: val, isSet: true}
|
|
}
|
|
|
|
func (v NullableMemoryItem) MarshalJSON() ([]byte, error) {
|
|
return json.Marshal(v.value)
|
|
}
|
|
|
|
func (v *NullableMemoryItem) UnmarshalJSON(src []byte) error {
|
|
v.isSet = true
|
|
return json.Unmarshal(src, &v.value)
|
|
}
|
|
|
|
|