File tree Expand file tree Collapse file tree 3 files changed +4
-4
lines changed Expand file tree Collapse file tree 3 files changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -118,7 +118,7 @@ def generate_template_config(
118
118
guard_instantiations = []
119
119
120
120
for i , guard in enumerate (template ["guards" ]):
121
- guard_instantiations .append (f"guard{ i } = AsyncGuard .from_dict(guards[{ i } ])" )
121
+ guard_instantiations .append (f"guard{ i } = Guard .from_dict(guards[{ i } ])" )
122
122
guard_instantiations = "\n " .join (guard_instantiations )
123
123
# Interpolate variables
124
124
output_content = template_content .format (
Original file line number Diff line number Diff line change 1
1
import json
2
2
import os
3
- from guardrails import AsyncGuard, Guard
3
+ from guardrails import Guard
4
4
from guardrails.hub import {VALIDATOR_IMPORTS}
5
5
6
6
try:
Original file line number Diff line number Diff line change 1
1
import json
2
2
import os
3
- from guardrails import AsyncGuard
3
+ from guardrails import Guard
4
4
5
5
try :
6
6
file_path = os .path .join (os .getcwd (), "guard-template.json" )
11
11
SystemExit (1 )
12
12
13
13
# instantiate guards
14
- guard0 = AsyncGuard .from_dict (guards [0 ])
14
+ guard0 = Guard .from_dict (guards [0 ])
You can’t perform that action at this time.
0 commit comments