diff --git a/.github/scripts/sheet2docs/config.yml b/.github/scripts/sheet2docs/config.yml index caf0fe40d12..6ce391c9e39 100644 --- a/.github/scripts/sheet2docs/config.yml +++ b/.github/scripts/sheet2docs/config.yml @@ -111,6 +111,14 @@ outputs: sort: by: "Name" direction: "ascending" +# + - filename: "decision-models.csv" + filter: + column: "Type" + values: ["Decision"] + sort: + by: "Name" + direction: "ascending" # # - filename: "all-models.csv" # # No filter: includes all rows diff --git a/.github/scripts/sheet2docs/sync_sheet.py b/.github/scripts/sheet2docs/sync_sheet.py index ff65d529421..6b85242aa78 100644 --- a/.github/scripts/sheet2docs/sync_sheet.py +++ b/.github/scripts/sheet2docs/sync_sheet.py @@ -785,7 +785,8 @@ def filter_columns( def write_csv( data: List[Dict[str, Any]], output_path: str, - delimiter: str = ',' + delimiter: str = ',', + fieldnames: Optional[List[str]] = None ) -> None: """ Write data to CSV file. @@ -794,6 +795,8 @@ def write_csv( data: List of row dictionaries output_path: Path where CSV should be written delimiter: CSV delimiter character (default: comma) + fieldnames: Column names, used to write a header-only file when + there are no rows (for example, a type with no models yet) Raises: SystemExit: If file cannot be written @@ -807,9 +810,10 @@ def write_csv( # Write CSV if not data: print("Warning: No data to write to CSV", file=sys.stderr) - # Write empty file with just headers + # Write a file with just the header row with open(output_path, 'w', newline='', encoding='utf-8') as f: - f.write('') + if fieldnames: + csv.writer(f, delimiter=delimiter).writerow(fieldnames) return # Get field names from first row @@ -899,7 +903,9 @@ def main(): output_dir = output_config.get('directory', '.') output_path = os.path.join(output_dir, filename) delimiter = output_config.get('delimiter', ',') - write_csv(output_data, output_path, delimiter) + fieldnames = [col.get('target', col['source']) + for col in output_config['columns']] + write_csv(output_data, output_path, delimiter, fieldnames) generated_paths.append(output_path) diff --git a/explore-analyze/elastic-inference/decision-models.csv b/explore-analyze/elastic-inference/decision-models.csv new file mode 100644 index 00000000000..7c1717e4c16 --- /dev/null +++ b/explore-analyze/elastic-inference/decision-models.csv @@ -0,0 +1 @@ +Author,Name,ID,Model Card,Provider Terms,Input Modalities,Output Modalities,EOL Date,Data Retention Period (Days),Data Used To Train Models?,Inference Regions,Release Status,Stack Version diff --git a/explore-analyze/elastic-inference/eis-supported-models.md b/explore-analyze/elastic-inference/eis-supported-models.md index fc32802e378..aba715561e8 100644 --- a/explore-analyze/elastic-inference/eis-supported-models.md +++ b/explore-analyze/elastic-inference/eis-supported-models.md @@ -40,6 +40,12 @@ For region availability and request routing, refer to [Region and hosting](eis-r :caption: Scroll horizontally to view more information. ::: +### Decision models + +:::{csv-include} decision-models.csv +:caption: Scroll horizontally to view more information. +::: + ::::{important} * The applicable terms of use, uptime, and performance for each of the AI models available with EIS are each described in the applicable AI model's Provider Terms and Model Card.