@takeshape/schema 11.17.4 → 11.17.6
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/dist/project-schema/latest.d.ts +74 -102
- package/dist/project-schema/latest.d.ts.map +1 -1
- package/dist/project-schema/v3.48.0.d.ts +74 -102
- package/dist/project-schema/v3.48.0.d.ts.map +1 -1
- package/dist/project-schema/v3.49.0.d.ts +74 -102
- package/dist/project-schema/v3.49.0.d.ts.map +1 -1
- package/dist/schemas/index.d.ts.map +1 -1
- package/dist/schemas/index.js +2 -1
- package/dist/schemas/index.ts +2 -0
- package/dist/schemas/project-schema/experimental.json +601 -0
- package/dist/schemas/project-schema/latest.json +2 -563
- package/dist/schemas/project-schema/v3.48.0.json +2 -563
- package/dist/schemas/project-schema/v3.49.0.json +2 -563
- package/dist/validate.d.ts.map +1 -1
- package/dist/validate.js +5 -2
- package/es/schemas/index.js +2 -1
- package/es/schemas/index.ts +2 -0
- package/es/schemas/project-schema/experimental.json +601 -0
- package/es/schemas/project-schema/latest.json +2 -563
- package/es/schemas/project-schema/v3.48.0.json +2 -563
- package/es/schemas/project-schema/v3.49.0.json +2 -563
- package/es/validate.js +5 -2
- package/package.json +5 -5
|
@@ -1056,7 +1056,7 @@
|
|
|
1056
1056
|
"$ref": "#/definitions/aiParseFileResolver"
|
|
1057
1057
|
},
|
|
1058
1058
|
{
|
|
1059
|
-
"$ref": "#/definitions/aiRunAgentResolver"
|
|
1059
|
+
"$ref": "https://schema.takeshape.io/project-schema/experimental#/definitions/aiRunAgentResolver"
|
|
1060
1060
|
}
|
|
1061
1061
|
]
|
|
1062
1062
|
},
|
|
@@ -1750,38 +1750,6 @@
|
|
|
1750
1750
|
],
|
|
1751
1751
|
"additionalProperties": false
|
|
1752
1752
|
},
|
|
1753
|
-
"aiRunAgentResolver": {
|
|
1754
|
-
"title": "AIRunAgentResolver",
|
|
1755
|
-
"type": "object",
|
|
1756
|
-
"properties": {
|
|
1757
|
-
"id": {
|
|
1758
|
-
"type": "string",
|
|
1759
|
-
"pattern": "^(?=[a-zA-Z])[-_a-zA-Z0-9]+$"
|
|
1760
|
-
},
|
|
1761
|
-
"name": {
|
|
1762
|
-
"title": "AI Resolver Name",
|
|
1763
|
-
"type": "string",
|
|
1764
|
-
"description": "Name of the resolver function.",
|
|
1765
|
-
"enum": [
|
|
1766
|
-
"ai:runAgent"
|
|
1767
|
-
]
|
|
1768
|
-
},
|
|
1769
|
-
"agentName": {
|
|
1770
|
-
"type": "string",
|
|
1771
|
-
"pattern": "^[0-9A-Za-z_]+$"
|
|
1772
|
-
},
|
|
1773
|
-
"inputStateId": {
|
|
1774
|
-
"type": "string",
|
|
1775
|
-
"pattern": "^[0-9A-Za-z_]+$"
|
|
1776
|
-
}
|
|
1777
|
-
},
|
|
1778
|
-
"required": [
|
|
1779
|
-
"name",
|
|
1780
|
-
"agentName",
|
|
1781
|
-
"inputStateId"
|
|
1782
|
-
],
|
|
1783
|
-
"additionalProperties": false
|
|
1784
|
-
},
|
|
1785
1753
|
"takeshapeResolver": {
|
|
1786
1754
|
"title": "TakeshapeResolver",
|
|
1787
1755
|
"type": "object",
|
|
@@ -2545,535 +2513,6 @@
|
|
|
2545
2513
|
},
|
|
2546
2514
|
"additionalProperties": false
|
|
2547
2515
|
},
|
|
2548
|
-
"agent": {
|
|
2549
|
-
"title": "Agent JSON",
|
|
2550
|
-
"description": "An Agent is a configuration for an AI service such as a chat bot or a search engine.",
|
|
2551
|
-
"type": "object",
|
|
2552
|
-
"properties": {
|
|
2553
|
-
"description": {
|
|
2554
|
-
"type": "string"
|
|
2555
|
-
},
|
|
2556
|
-
"states": {
|
|
2557
|
-
"$ref": "#/definitions/agentStateMap"
|
|
2558
|
-
}
|
|
2559
|
-
},
|
|
2560
|
-
"required": [
|
|
2561
|
-
"states"
|
|
2562
|
-
],
|
|
2563
|
-
"additionalProperties": false
|
|
2564
|
-
},
|
|
2565
|
-
"agentVariable": {
|
|
2566
|
-
"title": "Agent Variable",
|
|
2567
|
-
"type": "object",
|
|
2568
|
-
"properties": {
|
|
2569
|
-
"name": {
|
|
2570
|
-
"type": "string"
|
|
2571
|
-
},
|
|
2572
|
-
"steps": {
|
|
2573
|
-
"description": "These are evaluated in order until a value is found.",
|
|
2574
|
-
"type": "array",
|
|
2575
|
-
"items": {
|
|
2576
|
-
"$ref": "#/definitions/agentVariableStep"
|
|
2577
|
-
}
|
|
2578
|
-
}
|
|
2579
|
-
},
|
|
2580
|
-
"required": [
|
|
2581
|
-
"name",
|
|
2582
|
-
"steps"
|
|
2583
|
-
],
|
|
2584
|
-
"additionalProperties": false
|
|
2585
|
-
},
|
|
2586
|
-
"agentVariableStep": {
|
|
2587
|
-
"title": "Agent Variable Step",
|
|
2588
|
-
"discriminator": {
|
|
2589
|
-
"propertyName": "type"
|
|
2590
|
-
},
|
|
2591
|
-
"oneOf": [
|
|
2592
|
-
{
|
|
2593
|
-
"$ref": "#/definitions/agentVariableStepGraphqlArg"
|
|
2594
|
-
},
|
|
2595
|
-
{
|
|
2596
|
-
"$ref": "#/definitions/agentVariableStepStateOutput"
|
|
2597
|
-
},
|
|
2598
|
-
{
|
|
2599
|
-
"$ref": "#/definitions/agentVariableStepPreviousStateOutput"
|
|
2600
|
-
}
|
|
2601
|
-
]
|
|
2602
|
-
},
|
|
2603
|
-
"agentVariableStepGraphqlArg": {
|
|
2604
|
-
"title": "Agent Variable Step GraphQL Arg",
|
|
2605
|
-
"description": "An Agent Variable that defines a GraphQL argument and makes its value available to templates.",
|
|
2606
|
-
"type": "object",
|
|
2607
|
-
"properties": {
|
|
2608
|
-
"type": {
|
|
2609
|
-
"enum": [
|
|
2610
|
-
"graphqlArg"
|
|
2611
|
-
]
|
|
2612
|
-
},
|
|
2613
|
-
"argName": {
|
|
2614
|
-
"type": "string"
|
|
2615
|
-
}
|
|
2616
|
-
},
|
|
2617
|
-
"required": [
|
|
2618
|
-
"type",
|
|
2619
|
-
"argName"
|
|
2620
|
-
],
|
|
2621
|
-
"additionalProperties": false
|
|
2622
|
-
},
|
|
2623
|
-
"agentVariableStepPreviousStateOutput": {
|
|
2624
|
-
"title": "Agent Variable Step Previous State Output",
|
|
2625
|
-
"description": "An Agent Variable that provides the output of the previous state's execution.",
|
|
2626
|
-
"type": "object",
|
|
2627
|
-
"properties": {
|
|
2628
|
-
"type": {
|
|
2629
|
-
"enum": [
|
|
2630
|
-
"previousStateOutput"
|
|
2631
|
-
]
|
|
2632
|
-
},
|
|
2633
|
-
"path": {
|
|
2634
|
-
"type": "string"
|
|
2635
|
-
}
|
|
2636
|
-
},
|
|
2637
|
-
"required": [
|
|
2638
|
-
"type"
|
|
2639
|
-
],
|
|
2640
|
-
"additionalProperties": false
|
|
2641
|
-
},
|
|
2642
|
-
"agentVariableStepStateOutput": {
|
|
2643
|
-
"title": "Agent Variable Step State Output",
|
|
2644
|
-
"description": "An Agent Variable that provides the output of any previous state's execution.",
|
|
2645
|
-
"type": "object",
|
|
2646
|
-
"properties": {
|
|
2647
|
-
"type": {
|
|
2648
|
-
"enum": [
|
|
2649
|
-
"stateOutput"
|
|
2650
|
-
]
|
|
2651
|
-
},
|
|
2652
|
-
"stateId": {
|
|
2653
|
-
"type": "string",
|
|
2654
|
-
"pattern": "^[0-9A-Za-z_]+$"
|
|
2655
|
-
},
|
|
2656
|
-
"path": {
|
|
2657
|
-
"type": "string"
|
|
2658
|
-
}
|
|
2659
|
-
},
|
|
2660
|
-
"required": [
|
|
2661
|
-
"type",
|
|
2662
|
-
"stateId"
|
|
2663
|
-
],
|
|
2664
|
-
"additionalProperties": false
|
|
2665
|
-
},
|
|
2666
|
-
"agentStateMap": {
|
|
2667
|
-
"title": "Agent States",
|
|
2668
|
-
"description": "States that are traversed during the execution of an agent.",
|
|
2669
|
-
"type": "object",
|
|
2670
|
-
"patternProperties": {
|
|
2671
|
-
"^[0-9A-Za-z_]+$": {
|
|
2672
|
-
"$ref": "#/definitions/agentState"
|
|
2673
|
-
}
|
|
2674
|
-
},
|
|
2675
|
-
"additionalProperties": false
|
|
2676
|
-
},
|
|
2677
|
-
"agentState": {
|
|
2678
|
-
"title": "Agent State",
|
|
2679
|
-
"description": "One step of an agent's execution.",
|
|
2680
|
-
"type": "object",
|
|
2681
|
-
"properties": {
|
|
2682
|
-
"name": {
|
|
2683
|
-
"type": "string"
|
|
2684
|
-
},
|
|
2685
|
-
"variables": {
|
|
2686
|
-
"title": "Variables",
|
|
2687
|
-
"type": "array",
|
|
2688
|
-
"items": {
|
|
2689
|
-
"$ref": "#/definitions/agentVariable"
|
|
2690
|
-
}
|
|
2691
|
-
},
|
|
2692
|
-
"execution": {
|
|
2693
|
-
"$ref": "#/definitions/agentExecution"
|
|
2694
|
-
},
|
|
2695
|
-
"transition": {
|
|
2696
|
-
"title": "Agent State Transition",
|
|
2697
|
-
"description": "These are evaluated in order until a destination is found.",
|
|
2698
|
-
"type": "array",
|
|
2699
|
-
"items": {
|
|
2700
|
-
"default": {
|
|
2701
|
-
"valueCheck": {
|
|
2702
|
-
"type": "none"
|
|
2703
|
-
}
|
|
2704
|
-
},
|
|
2705
|
-
"$ref": "#/definitions/agentTransition"
|
|
2706
|
-
}
|
|
2707
|
-
}
|
|
2708
|
-
},
|
|
2709
|
-
"required": [
|
|
2710
|
-
"name",
|
|
2711
|
-
"execution"
|
|
2712
|
-
],
|
|
2713
|
-
"additionalProperties": false
|
|
2714
|
-
},
|
|
2715
|
-
"agentExecution": {
|
|
2716
|
-
"title": "Agent Execution",
|
|
2717
|
-
"discriminator": {
|
|
2718
|
-
"propertyName": "type"
|
|
2719
|
-
},
|
|
2720
|
-
"oneOf": [
|
|
2721
|
-
{
|
|
2722
|
-
"$ref": "#/definitions/agentExecutionNoop"
|
|
2723
|
-
},
|
|
2724
|
-
{
|
|
2725
|
-
"$ref": "#/definitions/agentExecutionInput"
|
|
2726
|
-
},
|
|
2727
|
-
{
|
|
2728
|
-
"$ref": "#/definitions/agentExecutionGraphql"
|
|
2729
|
-
},
|
|
2730
|
-
{
|
|
2731
|
-
"$ref": "#/definitions/agentExecutionGenerateText"
|
|
2732
|
-
},
|
|
2733
|
-
{
|
|
2734
|
-
"$ref": "#/definitions/agentExecutionChat"
|
|
2735
|
-
}
|
|
2736
|
-
]
|
|
2737
|
-
},
|
|
2738
|
-
"agentExecutionNoop": {
|
|
2739
|
-
"title": "Agent Execution No Operation",
|
|
2740
|
-
"type": "object",
|
|
2741
|
-
"properties": {
|
|
2742
|
-
"type": {
|
|
2743
|
-
"enum": [
|
|
2744
|
-
"noop"
|
|
2745
|
-
]
|
|
2746
|
-
}
|
|
2747
|
-
},
|
|
2748
|
-
"required": [
|
|
2749
|
-
"type"
|
|
2750
|
-
],
|
|
2751
|
-
"additionalProperties": false
|
|
2752
|
-
},
|
|
2753
|
-
"agentExecutionInputArgument": {
|
|
2754
|
-
"title": "Agent Execution Input Argument",
|
|
2755
|
-
"type": "object",
|
|
2756
|
-
"properties": {
|
|
2757
|
-
"argName": {
|
|
2758
|
-
"type": "string",
|
|
2759
|
-
"pattern": "^[0-9A-Za-z_]+$"
|
|
2760
|
-
},
|
|
2761
|
-
"argType": {
|
|
2762
|
-
"enum": [
|
|
2763
|
-
"boolean",
|
|
2764
|
-
"integer",
|
|
2765
|
-
"number",
|
|
2766
|
-
"string"
|
|
2767
|
-
]
|
|
2768
|
-
},
|
|
2769
|
-
"required": {
|
|
2770
|
-
"type": "boolean"
|
|
2771
|
-
}
|
|
2772
|
-
},
|
|
2773
|
-
"required": [
|
|
2774
|
-
"argName",
|
|
2775
|
-
"argType"
|
|
2776
|
-
],
|
|
2777
|
-
"additionalProperties": false
|
|
2778
|
-
},
|
|
2779
|
-
"agentExecutionInput": {
|
|
2780
|
-
"title": "Agent Execution Input",
|
|
2781
|
-
"type": "object",
|
|
2782
|
-
"properties": {
|
|
2783
|
-
"type": {
|
|
2784
|
-
"enum": [
|
|
2785
|
-
"input"
|
|
2786
|
-
]
|
|
2787
|
-
},
|
|
2788
|
-
"name": {
|
|
2789
|
-
"type": "string",
|
|
2790
|
-
"pattern": "^[0-9A-Za-z_]+$"
|
|
2791
|
-
},
|
|
2792
|
-
"inputType": {
|
|
2793
|
-
"enum": [
|
|
2794
|
-
"query",
|
|
2795
|
-
"mutation"
|
|
2796
|
-
]
|
|
2797
|
-
},
|
|
2798
|
-
"arguments": {
|
|
2799
|
-
"type": "array",
|
|
2800
|
-
"items": {
|
|
2801
|
-
"$ref": "#/definitions/agentExecutionInputArgument"
|
|
2802
|
-
}
|
|
2803
|
-
}
|
|
2804
|
-
},
|
|
2805
|
-
"required": [
|
|
2806
|
-
"type",
|
|
2807
|
-
"name",
|
|
2808
|
-
"inputType"
|
|
2809
|
-
],
|
|
2810
|
-
"additionalProperties": false
|
|
2811
|
-
},
|
|
2812
|
-
"agentExecutionGraphql": {
|
|
2813
|
-
"title": "Agent Execution GraphQL",
|
|
2814
|
-
"type": "object",
|
|
2815
|
-
"properties": {
|
|
2816
|
-
"type": {
|
|
2817
|
-
"enum": [
|
|
2818
|
-
"graphql"
|
|
2819
|
-
]
|
|
2820
|
-
},
|
|
2821
|
-
"query": {
|
|
2822
|
-
"type": "string"
|
|
2823
|
-
},
|
|
2824
|
-
"path": {
|
|
2825
|
-
"type": "string"
|
|
2826
|
-
}
|
|
2827
|
-
},
|
|
2828
|
-
"required": [
|
|
2829
|
-
"type",
|
|
2830
|
-
"query"
|
|
2831
|
-
],
|
|
2832
|
-
"additionalProperties": false
|
|
2833
|
-
},
|
|
2834
|
-
"agentAiStateInputArg": {
|
|
2835
|
-
"title": "Agent AI State Input Argument",
|
|
2836
|
-
"type": "object",
|
|
2837
|
-
"properties": {
|
|
2838
|
-
"type": {
|
|
2839
|
-
"enum": [
|
|
2840
|
-
"arg"
|
|
2841
|
-
]
|
|
2842
|
-
},
|
|
2843
|
-
"inputArgName": {
|
|
2844
|
-
"type": "string"
|
|
2845
|
-
}
|
|
2846
|
-
},
|
|
2847
|
-
"required": [
|
|
2848
|
-
"type",
|
|
2849
|
-
"inputArgName"
|
|
2850
|
-
]
|
|
2851
|
-
},
|
|
2852
|
-
"agentAiStateInputTemplate": {
|
|
2853
|
-
"title": "Agent AI State Input Template",
|
|
2854
|
-
"type": "object",
|
|
2855
|
-
"properties": {
|
|
2856
|
-
"type": {
|
|
2857
|
-
"enum": [
|
|
2858
|
-
"template"
|
|
2859
|
-
]
|
|
2860
|
-
},
|
|
2861
|
-
"inputTemplate": {
|
|
2862
|
-
"type": "string"
|
|
2863
|
-
}
|
|
2864
|
-
},
|
|
2865
|
-
"required": [
|
|
2866
|
-
"type",
|
|
2867
|
-
"inputTemplate"
|
|
2868
|
-
]
|
|
2869
|
-
},
|
|
2870
|
-
"agentAiStateInput": {
|
|
2871
|
-
"title": "Agent AI State Input",
|
|
2872
|
-
"type": "object",
|
|
2873
|
-
"discriminator": {
|
|
2874
|
-
"propertyName": "type"
|
|
2875
|
-
},
|
|
2876
|
-
"oneOf": [
|
|
2877
|
-
{
|
|
2878
|
-
"$ref": "#/definitions/agentAiStateInputArg"
|
|
2879
|
-
},
|
|
2880
|
-
{
|
|
2881
|
-
"$ref": "#/definitions/agentAiStateInputTemplate"
|
|
2882
|
-
}
|
|
2883
|
-
]
|
|
2884
|
-
},
|
|
2885
|
-
"agentExecutionGenerateText": {
|
|
2886
|
-
"title": "Agent Execution Generate Text",
|
|
2887
|
-
"type": "object",
|
|
2888
|
-
"properties": {
|
|
2889
|
-
"type": {
|
|
2890
|
-
"enum": [
|
|
2891
|
-
"generateText"
|
|
2892
|
-
]
|
|
2893
|
-
},
|
|
2894
|
-
"service": {
|
|
2895
|
-
"type": "string"
|
|
2896
|
-
},
|
|
2897
|
-
"model": {
|
|
2898
|
-
"type": "string"
|
|
2899
|
-
},
|
|
2900
|
-
"systemPrompt": {
|
|
2901
|
-
"type": "string"
|
|
2902
|
-
},
|
|
2903
|
-
"input": {
|
|
2904
|
-
"$ref": "#/definitions/agentAiStateInput"
|
|
2905
|
-
},
|
|
2906
|
-
"jsonSchema": {
|
|
2907
|
-
"type": "string"
|
|
2908
|
-
},
|
|
2909
|
-
"tools": {
|
|
2910
|
-
"type": "array",
|
|
2911
|
-
"items": {
|
|
2912
|
-
"oneOf": [
|
|
2913
|
-
{
|
|
2914
|
-
"$ref": "#/definitions/aiToolConfig"
|
|
2915
|
-
}
|
|
2916
|
-
]
|
|
2917
|
-
}
|
|
2918
|
-
},
|
|
2919
|
-
"guardrails": {
|
|
2920
|
-
"type": "array",
|
|
2921
|
-
"items": {
|
|
2922
|
-
"$ref": "#/definitions/aiGuardrail"
|
|
2923
|
-
}
|
|
2924
|
-
},
|
|
2925
|
-
"options": {
|
|
2926
|
-
"$ref": "#/definitions/aiGenerateTextResolverOptions"
|
|
2927
|
-
}
|
|
2928
|
-
},
|
|
2929
|
-
"required": [
|
|
2930
|
-
"type",
|
|
2931
|
-
"service",
|
|
2932
|
-
"model",
|
|
2933
|
-
"input"
|
|
2934
|
-
],
|
|
2935
|
-
"additionalProperties": false
|
|
2936
|
-
},
|
|
2937
|
-
"agentExecutionChat": {
|
|
2938
|
-
"title": "Agent Execution Chat",
|
|
2939
|
-
"type": "object",
|
|
2940
|
-
"properties": {
|
|
2941
|
-
"type": {
|
|
2942
|
-
"enum": [
|
|
2943
|
-
"chat"
|
|
2944
|
-
]
|
|
2945
|
-
},
|
|
2946
|
-
"service": {
|
|
2947
|
-
"type": "string"
|
|
2948
|
-
},
|
|
2949
|
-
"model": {
|
|
2950
|
-
"type": "string"
|
|
2951
|
-
},
|
|
2952
|
-
"systemPrompt": {
|
|
2953
|
-
"type": "string"
|
|
2954
|
-
},
|
|
2955
|
-
"input": {
|
|
2956
|
-
"$ref": "#/definitions/agentAiStateInput"
|
|
2957
|
-
},
|
|
2958
|
-
"tools": {
|
|
2959
|
-
"type": "array",
|
|
2960
|
-
"items": {
|
|
2961
|
-
"oneOf": [
|
|
2962
|
-
{
|
|
2963
|
-
"$ref": "#/definitions/aiToolConfig"
|
|
2964
|
-
}
|
|
2965
|
-
]
|
|
2966
|
-
}
|
|
2967
|
-
},
|
|
2968
|
-
"sessionArg": {
|
|
2969
|
-
"type": "string"
|
|
2970
|
-
},
|
|
2971
|
-
"guardrails": {
|
|
2972
|
-
"type": "array",
|
|
2973
|
-
"items": {
|
|
2974
|
-
"$ref": "#/definitions/aiGuardrail"
|
|
2975
|
-
}
|
|
2976
|
-
},
|
|
2977
|
-
"options": {
|
|
2978
|
-
"$ref": "#/definitions/aiGenerateTextResolverOptions"
|
|
2979
|
-
}
|
|
2980
|
-
},
|
|
2981
|
-
"required": [
|
|
2982
|
-
"type",
|
|
2983
|
-
"service",
|
|
2984
|
-
"model",
|
|
2985
|
-
"input",
|
|
2986
|
-
"sessionArg"
|
|
2987
|
-
],
|
|
2988
|
-
"additionalProperties": false
|
|
2989
|
-
},
|
|
2990
|
-
"valueCheckNone": {
|
|
2991
|
-
"title": "Value Check None",
|
|
2992
|
-
"type": "object",
|
|
2993
|
-
"properties": {
|
|
2994
|
-
"type": {
|
|
2995
|
-
"enum": [
|
|
2996
|
-
"none"
|
|
2997
|
-
]
|
|
2998
|
-
}
|
|
2999
|
-
},
|
|
3000
|
-
"required": [
|
|
3001
|
-
"type"
|
|
3002
|
-
]
|
|
3003
|
-
},
|
|
3004
|
-
"valueCheckBoolean": {
|
|
3005
|
-
"title": "Value Check Boolean",
|
|
3006
|
-
"type": "object",
|
|
3007
|
-
"properties": {
|
|
3008
|
-
"type": {
|
|
3009
|
-
"enum": [
|
|
3010
|
-
"boolean"
|
|
3011
|
-
]
|
|
3012
|
-
},
|
|
3013
|
-
"path": {
|
|
3014
|
-
"type": "string"
|
|
3015
|
-
},
|
|
3016
|
-
"negated": {
|
|
3017
|
-
"type": "boolean"
|
|
3018
|
-
}
|
|
3019
|
-
},
|
|
3020
|
-
"required": [
|
|
3021
|
-
"type",
|
|
3022
|
-
"path"
|
|
3023
|
-
]
|
|
3024
|
-
},
|
|
3025
|
-
"agentTransition": {
|
|
3026
|
-
"title": "Agent Transition",
|
|
3027
|
-
"type": "object",
|
|
3028
|
-
"properties": {
|
|
3029
|
-
"valueCheck": {
|
|
3030
|
-
"discriminator": {
|
|
3031
|
-
"propertyName": "type"
|
|
3032
|
-
},
|
|
3033
|
-
"oneOf": [
|
|
3034
|
-
{
|
|
3035
|
-
"$ref": "#/definitions/valueCheckNone"
|
|
3036
|
-
},
|
|
3037
|
-
{
|
|
3038
|
-
"$ref": "#/definitions/valueCheckBoolean"
|
|
3039
|
-
}
|
|
3040
|
-
]
|
|
3041
|
-
},
|
|
3042
|
-
"limit": {
|
|
3043
|
-
"type": "integer"
|
|
3044
|
-
},
|
|
3045
|
-
"destination": {
|
|
3046
|
-
"type": "string",
|
|
3047
|
-
"pattern": "^[0-9A-Za-z_]+$"
|
|
3048
|
-
}
|
|
3049
|
-
},
|
|
3050
|
-
"additionalProperties": false,
|
|
3051
|
-
"required": [
|
|
3052
|
-
"valueCheck",
|
|
3053
|
-
"destination"
|
|
3054
|
-
]
|
|
3055
|
-
},
|
|
3056
|
-
"aiExperimental": {
|
|
3057
|
-
"title": "AI Experimental",
|
|
3058
|
-
"type": "object",
|
|
3059
|
-
"properties": {
|
|
3060
|
-
"agents": {
|
|
3061
|
-
"$ref": "#/definitions/agentMap",
|
|
3062
|
-
"description": "An Agent is a configuration for an AI service such as a chat bot or a search engine."
|
|
3063
|
-
}
|
|
3064
|
-
},
|
|
3065
|
-
"additionalProperties": false
|
|
3066
|
-
},
|
|
3067
|
-
"agentMap": {
|
|
3068
|
-
"title": "Agent Map",
|
|
3069
|
-
"type": "object",
|
|
3070
|
-
"patternProperties": {
|
|
3071
|
-
"^[0-9A-Za-z_]+$": {
|
|
3072
|
-
"$ref": "#/definitions/agent"
|
|
3073
|
-
}
|
|
3074
|
-
},
|
|
3075
|
-
"additionalProperties": false
|
|
3076
|
-
},
|
|
3077
2516
|
"formMap": {
|
|
3078
2517
|
"title": "Form Map",
|
|
3079
2518
|
"type": "object",
|
|
@@ -4195,7 +3634,7 @@
|
|
|
4195
3634
|
"description": "A Shape is a schema object for structuring and storing data from one or more sources, including the TakeShape data store and connected services."
|
|
4196
3635
|
},
|
|
4197
3636
|
"ai-experimental": {
|
|
4198
|
-
"$ref": "#/definitions/aiExperimental",
|
|
3637
|
+
"$ref": "https://schema.takeshape.io/project-schema/experimental#/definitions/aiExperimental",
|
|
4199
3638
|
"description": "Unstable AI features that will not be migrated when removed. Not suitable for production use."
|
|
4200
3639
|
},
|
|
4201
3640
|
"forms": {
|
package/dist/validate.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"validate.d.ts","sourceRoot":"","sources":["../../src/validate.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAmB,WAAW,EAAC,MAAM,KAAK,CAAC;AAGvD,OAAO,EAAwB,KAAK,yBAAyB,EAAC,MAAM,mBAAmB,CAAC;
|
|
1
|
+
{"version":3,"file":"validate.d.ts","sourceRoot":"","sources":["../../src/validate.ts"],"names":[],"mappings":"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"}
|
package/dist/validate.js
CHANGED
|
@@ -18,6 +18,7 @@ var _errors = require("@takeshape/errors");
|
|
|
18
18
|
var _coerce = _interopRequireDefault(require("semver/functions/coerce"));
|
|
19
19
|
var _neq = _interopRequireDefault(require("semver/functions/neq"));
|
|
20
20
|
var _lt = _interopRequireDefault(require("semver/functions/lt"));
|
|
21
|
+
var _gte = _interopRequireDefault(require("semver/functions/gte"));
|
|
21
22
|
var _isUndefined = _interopRequireDefault(require("lodash/isUndefined"));
|
|
22
23
|
var _util = require("@takeshape/util");
|
|
23
24
|
var _uniqBy = _interopRequireDefault(require("lodash/uniqBy"));
|
|
@@ -876,8 +877,10 @@ function isValidateReferencesContext(context) {
|
|
|
876
877
|
}
|
|
877
878
|
const ajv = (0, _jsonSchema.createAjv)();
|
|
878
879
|
function validateStructure(schemaVersion, context, schema, ref) {
|
|
879
|
-
const
|
|
880
|
-
const
|
|
880
|
+
const coerced = (0, _coerce.default)(schemaVersion);
|
|
881
|
+
const versionStr = coerced?.format();
|
|
882
|
+
const hasExperimental = Boolean(coerced && (0, _gte.default)(coerced, '3.48.0'));
|
|
883
|
+
const relevantSchemas = _schemas.allProjectSchemas.filter(metaSchema => hasExperimental && metaSchema.$id.endsWith('experimental#') || metaSchema.$id.endsWith(`v${versionStr}#`));
|
|
881
884
|
for (const relevantSchema of relevantSchemas) {
|
|
882
885
|
if (!ajv.getSchema(relevantSchema.$id)) {
|
|
883
886
|
ajv.addSchema(relevantSchema);
|
package/es/schemas/index.js
CHANGED
|
@@ -2,6 +2,7 @@
|
|
|
2
2
|
export const CURRENT_SCHEMA_VERSION = '3.49.0';
|
|
3
3
|
export { default as anyProjectSchema } from './project-schema.json';
|
|
4
4
|
export { default as latestSchemaJson } from './project-schema/v3.49.0.json';
|
|
5
|
+
import experimentalSchemaJson from './project-schema/experimental.json';
|
|
5
6
|
import metaSchemaV1_0_0 from './project-schema/meta-schema-v1.0.0.json';
|
|
6
7
|
import projectSchemaV1_0_0 from './project-schema/v1.0.0.json';
|
|
7
8
|
import metaSchemaV3_0_0 from './project-schema/meta-schema-v3.0.0.json';
|
|
@@ -73,4 +74,4 @@ import projectSchemaV3_47_0 from './project-schema/v3.47.0.json';
|
|
|
73
74
|
import projectSchemaV3_48_0 from './project-schema/v3.48.0.json';
|
|
74
75
|
import projectSchemaV3_49_0 from './project-schema/v3.49.0.json';
|
|
75
76
|
import projectSchemaV4_0_0 from './project-schema/v4.0.0.json';
|
|
76
|
-
export const allProjectSchemas = [metaSchemaV1_0_0, projectSchemaV1_0_0, metaSchemaV3_0_0, projectSchemaV3_0_0, metaSchemaV3_1_0, projectSchemaV3_1_0, metaSchemaV3_2_0, projectSchemaV3_2_0, metaSchemaV3_3_0, projectSchemaV3_3_0, metaSchemaV3_4_0, projectSchemaV3_4_0, metaSchemaV3_5_0, projectSchemaV3_5_0, metaSchemaV3_5_1, projectSchemaV3_5_1, metaSchemaV3_6_0, projectSchemaV3_6_0, metaSchemaV3_7_0, projectSchemaV3_7_0, metaSchemaV3_8_0, projectSchemaV3_8_0, metaSchemaV3_9_0, projectSchemaV3_9_0, projectSchemaV3_10_0, projectSchemaV3_11_0, projectSchemaV3_12_0, projectSchemaV3_12_1, projectSchemaV3_12_2, projectSchemaV3_12_3, projectSchemaV3_13_0, projectSchemaV3_14_0, projectSchemaV3_15_0, projectSchemaV3_16_0, projectSchemaV3_17_0, projectSchemaV3_17_1, projectSchemaV3_18_0, projectSchemaV3_18_1, projectSchemaV3_18_2, projectSchemaV3_19_0, projectSchemaV3_20_0, projectSchemaV3_21_0, projectSchemaV3_22_0, projectSchemaV3_23_0, projectSchemaV3_24_0, projectSchemaV3_25_0, projectSchemaV3_26_0, projectSchemaV3_27_0, projectSchemaV3_28_0, projectSchemaV3_29_0, projectSchemaV3_30_0, projectSchemaV3_31_0, projectSchemaV3_32_0, projectSchemaV3_33_0, projectSchemaV3_34_0, projectSchemaV3_35_0, projectSchemaV3_36_0, projectSchemaV3_37_0, projectSchemaV3_38_0, projectSchemaV3_39_0, projectSchemaV3_40_0, projectSchemaV3_41_0, projectSchemaV3_42_0, projectSchemaV3_43_0, projectSchemaV3_44_0, projectSchemaV3_45_0, projectSchemaV3_46_0, projectSchemaV3_47_0, projectSchemaV3_48_0, projectSchemaV3_49_0, projectSchemaV4_0_0];
|
|
77
|
+
export const allProjectSchemas = [experimentalSchemaJson, metaSchemaV1_0_0, projectSchemaV1_0_0, metaSchemaV3_0_0, projectSchemaV3_0_0, metaSchemaV3_1_0, projectSchemaV3_1_0, metaSchemaV3_2_0, projectSchemaV3_2_0, metaSchemaV3_3_0, projectSchemaV3_3_0, metaSchemaV3_4_0, projectSchemaV3_4_0, metaSchemaV3_5_0, projectSchemaV3_5_0, metaSchemaV3_5_1, projectSchemaV3_5_1, metaSchemaV3_6_0, projectSchemaV3_6_0, metaSchemaV3_7_0, projectSchemaV3_7_0, metaSchemaV3_8_0, projectSchemaV3_8_0, metaSchemaV3_9_0, projectSchemaV3_9_0, projectSchemaV3_10_0, projectSchemaV3_11_0, projectSchemaV3_12_0, projectSchemaV3_12_1, projectSchemaV3_12_2, projectSchemaV3_12_3, projectSchemaV3_13_0, projectSchemaV3_14_0, projectSchemaV3_15_0, projectSchemaV3_16_0, projectSchemaV3_17_0, projectSchemaV3_17_1, projectSchemaV3_18_0, projectSchemaV3_18_1, projectSchemaV3_18_2, projectSchemaV3_19_0, projectSchemaV3_20_0, projectSchemaV3_21_0, projectSchemaV3_22_0, projectSchemaV3_23_0, projectSchemaV3_24_0, projectSchemaV3_25_0, projectSchemaV3_26_0, projectSchemaV3_27_0, projectSchemaV3_28_0, projectSchemaV3_29_0, projectSchemaV3_30_0, projectSchemaV3_31_0, projectSchemaV3_32_0, projectSchemaV3_33_0, projectSchemaV3_34_0, projectSchemaV3_35_0, projectSchemaV3_36_0, projectSchemaV3_37_0, projectSchemaV3_38_0, projectSchemaV3_39_0, projectSchemaV3_40_0, projectSchemaV3_41_0, projectSchemaV3_42_0, projectSchemaV3_43_0, projectSchemaV3_44_0, projectSchemaV3_45_0, projectSchemaV3_46_0, projectSchemaV3_47_0, projectSchemaV3_48_0, projectSchemaV3_49_0, projectSchemaV4_0_0];
|
package/es/schemas/index.ts
CHANGED
|
@@ -2,6 +2,7 @@
|
|
|
2
2
|
export const CURRENT_SCHEMA_VERSION = '3.49.0';
|
|
3
3
|
export {default as anyProjectSchema} from './project-schema.json';
|
|
4
4
|
export {default as latestSchemaJson} from './project-schema/v3.49.0.json';
|
|
5
|
+
import experimentalSchemaJson from './project-schema/experimental.json';
|
|
5
6
|
import metaSchemaV1_0_0 from './project-schema/meta-schema-v1.0.0.json';
|
|
6
7
|
import projectSchemaV1_0_0 from './project-schema/v1.0.0.json';
|
|
7
8
|
import metaSchemaV3_0_0 from './project-schema/meta-schema-v3.0.0.json';
|
|
@@ -74,6 +75,7 @@ import projectSchemaV3_48_0 from './project-schema/v3.48.0.json';
|
|
|
74
75
|
import projectSchemaV3_49_0 from './project-schema/v3.49.0.json';
|
|
75
76
|
import projectSchemaV4_0_0 from './project-schema/v4.0.0.json';
|
|
76
77
|
export const allProjectSchemas = [
|
|
78
|
+
experimentalSchemaJson,
|
|
77
79
|
metaSchemaV1_0_0,
|
|
78
80
|
projectSchemaV1_0_0,
|
|
79
81
|
metaSchemaV3_0_0,
|