l = $l10nFactory->get('lib'); } /** * @inheritDoc * @since 30.0.0 */ public function getName(): string { return $this->l->t('Summarize'); } /** * @inheritDoc * @since 30.0.0 */ public function getDescription(): string { return $this->l->t('Summarizes a text'); } /** * @return string * @since 30.0.0 */ public function getId(): string { return self::ID; } /** * @return ShapeDescriptor[] * @since 30.0.0 */ public function getInputShape(): array { return [ 'input' => new ShapeDescriptor( $this->l->t('Original text'), $this->l->t('The original text to summarize'), EShapeType::Text ), ]; } /** * @return ShapeDescriptor[] * @since 30.0.0 */ public function getOutputShape(): array { return [ 'output' => new ShapeDescriptor( $this->l->t('Summary'), $this->l->t('The generated summary'), EShapeType::Text ), ]; } }