File manager - Edit - /usr/lib/python3/dist-packages/sos/report/plugins/__pycache__/instructlab.cpython-310.pyc
Back
o -�_g� � @ s2 d dl Z d dlmZmZmZ G dd� dee�ZdS )� N)�Plugin�IndependentPlugin� PluginOptc @ sX e Zd ZdZd ZdZdZdZdZe dde dd �e d de dd �e d ddd�gZdd� ZdS )�InstructlabaL This plugin is used to capture information about Instructlab installations. InstructLab is an open source project for enhancing large language models (LLMs) used in generative artificial intelligence (gen AI) applications. Instructlab can run either as a container, or directly outside a container. �instructlab)�ai)r �ilab)r � ilab-userz cloud-userzuser that runs instructlab)�default�val_type�desc� ilab-conf-dir� zinstructlab data directory� get-cacheFz#Capture models and osci cached data)r r c s d}d}d}d}d}�� ||�}�� ||�}�� ||�� ���� � d��� � d��� |d��� |d �g� g d �}g d�} z��d�d d } W n tyS d } Y nw �j|� d�|� d�g| d� �j� �fdd�| D �| d� �jdd� |D �| d� �j|d| d� ��d�r��j|� | d� ��t �j �� ��d�}zt�|�}W n t y� ��d|� d�� Y d S w |�r|j} ��d�rψ� | ��d��} �� | |������ | |�� ����fdd�| D �� �j�� | |�dd� ��d��r ���� | |�� d S d S d S )Nz/usr/share/instructlab/configz/opt/app-root/srcz.cache/instructlabz.config/instructlabz.local/share/instructlabz taxonomy/.gitztaxonomy/.githubz*src/.local/share/instructlab/taxonomy/.gitz-src/.local/share/instructlab/taxonomy/.github)z taxonomy diffz#taxonomy diff --taxonomy-base=emptyzsystem infoz model listzconfig show) �data� generated�taxonomy� taxonomy_data�chatlogs�checkpoints�datasets�internal�phasedzinstructlab*r � z/rhel_ai_config.yamlz/config.yaml)� containerc � g | ]}�� � |��qS � �� path_join��.0�data_dir)�cont_local_path�selfr �@/usr/lib/python3/dist-packages/sos/report/plugins/instructlab.py� <listcomp>g s �z%Instructlab.setup.<locals>.<listcomp>c S s g | ]}d |� ��qS )zilab r )r �subr r r$ r% l s T)� recursiver r r zUser "z�" does not exist, will not collect Instructlab information. Use `-k instructlab.ilab-user` option to define the user to use to collect data for Instructlabr c r r r r )�data_dirs_baser# r r$ r% � s ��)r'