@ax-llm/ax 14.0.44 → 15.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/index.d.cts CHANGED
@@ -918,6 +918,7 @@ declare class AxSignature<_TInput extends Record<string, any> = Record<string, a
918
918
  private updateHashLight;
919
919
  private updateHash;
920
920
  private validateSignatureConsistency;
921
+ hasComplexFields: () => boolean;
921
922
  validate: () => boolean;
922
923
  hash: () => string;
923
924
  toString: () => string;
@@ -1945,6 +1946,34 @@ declare class AxPromptTemplate {
1945
1946
  private readonly functions?;
1946
1947
  private readonly cacheSystemPrompt?;
1947
1948
  constructor(sig: Readonly<AxSignature>, options?: Readonly<AxPromptTemplateOptions>, fieldTemplates?: Record<string, AxFieldTemplateFn>);
1949
+ /**
1950
+ * Build legacy prompt format (backward compatible)
1951
+ */
1952
+ private buildLegacyPrompt;
1953
+ /**
1954
+ * Build XML-structured prompt with format protection
1955
+ */
1956
+ private buildStructuredPrompt;
1957
+ /**
1958
+ * Build identity section describing the task
1959
+ */
1960
+ private buildIdentitySection;
1961
+ /**
1962
+ * Build functions section with available functions
1963
+ */
1964
+ private buildFunctionsSection;
1965
+ /**
1966
+ * Build input fields section
1967
+ */
1968
+ private buildInputFieldsSection;
1969
+ /**
1970
+ * Build output fields section
1971
+ */
1972
+ private buildOutputFieldsSection;
1973
+ /**
1974
+ * Build formatting rules section with protection
1975
+ */
1976
+ private buildFormattingRulesSection;
1948
1977
  private renderSingleValueUserContent;
1949
1978
  render: <T = any>(values: T | ReadonlyArray<AxMessage<T>>, // Allow T or array of AxMessages
1950
1979
  { examples, demos, }: Readonly<{
@@ -5797,6 +5826,7 @@ interface AxFieldProcessor {
5797
5826
  type AxFunctionResultFormatter = (result: unknown) => string;
5798
5827
  declare const axGlobals: {
5799
5828
  signatureStrict: boolean;
5829
+ useStructuredPrompt: boolean;
5800
5830
  tracer: Tracer | undefined;
5801
5831
  meter: Meter | undefined;
5802
5832
  logger: AxLoggerFunction | undefined;
package/index.d.ts CHANGED
@@ -918,6 +918,7 @@ declare class AxSignature<_TInput extends Record<string, any> = Record<string, a
918
918
  private updateHashLight;
919
919
  private updateHash;
920
920
  private validateSignatureConsistency;
921
+ hasComplexFields: () => boolean;
921
922
  validate: () => boolean;
922
923
  hash: () => string;
923
924
  toString: () => string;
@@ -1945,6 +1946,34 @@ declare class AxPromptTemplate {
1945
1946
  private readonly functions?;
1946
1947
  private readonly cacheSystemPrompt?;
1947
1948
  constructor(sig: Readonly<AxSignature>, options?: Readonly<AxPromptTemplateOptions>, fieldTemplates?: Record<string, AxFieldTemplateFn>);
1949
+ /**
1950
+ * Build legacy prompt format (backward compatible)
1951
+ */
1952
+ private buildLegacyPrompt;
1953
+ /**
1954
+ * Build XML-structured prompt with format protection
1955
+ */
1956
+ private buildStructuredPrompt;
1957
+ /**
1958
+ * Build identity section describing the task
1959
+ */
1960
+ private buildIdentitySection;
1961
+ /**
1962
+ * Build functions section with available functions
1963
+ */
1964
+ private buildFunctionsSection;
1965
+ /**
1966
+ * Build input fields section
1967
+ */
1968
+ private buildInputFieldsSection;
1969
+ /**
1970
+ * Build output fields section
1971
+ */
1972
+ private buildOutputFieldsSection;
1973
+ /**
1974
+ * Build formatting rules section with protection
1975
+ */
1976
+ private buildFormattingRulesSection;
1948
1977
  private renderSingleValueUserContent;
1949
1978
  render: <T = any>(values: T | ReadonlyArray<AxMessage<T>>, // Allow T or array of AxMessages
1950
1979
  { examples, demos, }: Readonly<{
@@ -5797,6 +5826,7 @@ interface AxFieldProcessor {
5797
5826
  type AxFunctionResultFormatter = (result: unknown) => string;
5798
5827
  declare const axGlobals: {
5799
5828
  signatureStrict: boolean;
5829
+ useStructuredPrompt: boolean;
5800
5830
  tracer: Tracer | undefined;
5801
5831
  meter: Meter | undefined;
5802
5832
  logger: AxLoggerFunction | undefined;