MCPcopy Create free account
hub / github.com/simstudioai/sim / buildModelCapabilityFacts

Function buildModelCapabilityFacts

apps/sim/app/(landing)/models/utils.ts:753–813  ·  view source on GitHub ↗
(model: CatalogModel)

Source from the content-addressed store, hash-verified

751}
752
753export function buildModelCapabilityFacts(model: CatalogModel): CapabilityFact[] {
754 const { capabilities } = model
755 const supportsStructuredOutputs = supportsCatalogStructuredOutputs(capabilities)
756
757 return [
758 {
759 label: 'Temperature',
760 value: capabilities.temperature
761 ? `${capabilities.temperature.min} to ${capabilities.temperature.max}`
762 : 'Not configurable',
763 },
764 {
765 label: 'Reasoning effort',
766 value: capabilities.reasoningEffort
767 ? capabilities.reasoningEffort.values.join(', ')
768 : 'Not supported',
769 },
770 {
771 label: 'Verbosity',
772 value: capabilities.verbosity ? capabilities.verbosity.values.join(', ') : 'Not supported',
773 },
774 {
775 label: 'Thinking levels',
776 value: capabilities.thinking
777 ? `${capabilities.thinking.levels.join(', ')}${
778 capabilities.thinking.default ? ` (default: ${capabilities.thinking.default})` : ''
779 }`
780 : 'Not supported',
781 },
782 {
783 label: 'Structured outputs',
784 value: supportsStructuredOutputs
785 ? capabilities.nativeStructuredOutputs
786 ? 'Supported (native)'
787 : 'Supported'
788 : 'Not supported',
789 },
790 {
791 label: 'Tool choice',
792 value: formatCapabilityBoolean(capabilities.toolUsageControl),
793 },
794 {
795 label: 'Computer use',
796 value: formatCapabilityBoolean(capabilities.computerUse),
797 },
798 {
799 label: 'Deep research',
800 value: formatCapabilityBoolean(capabilities.deepResearch),
801 },
802 {
803 label: 'Memory support',
804 value: capabilities.memory === false ? 'Disabled' : 'Supported',
805 },
806 {
807 label: 'Max output tokens',
808 value: capabilities.maxOutputTokens
809 ? formatTokenCount(getEffectiveMaxOutputTokens(capabilities))
810 : 'Not published',

Callers 2

utils.test.tsFile · 0.90
ModelPageFunction · 0.90

Calls 5

formatCapabilityBooleanFunction · 0.85
joinMethod · 0.80
formatTokenCountFunction · 0.70

Tested by

no test coverage detected