src/mcp_server_aliyun_observability/toolkit/arms_toolkit.py [224:257]:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
        ) -> dict:
            """分析ARMS应用火焰图性能热点。

            ## 功能概述

            当应用存在性能问题且开启持续剖析时，可以调用该工具对ARMS应用火焰图性能热点进行分析，生成分析结果。分析结果会包含火焰图的性能热点问题、优化建议等信息。

            ## 使用场景

            - 当需要分析ARMS应用火焰图性能问题时

            ## 查询示例

            - "帮我分析下ARMS应用 XXX 的火焰图性能热点"

            Args:
                ctx: MCP上下文，用于访问SLS客户端
                pid: ARMS应用监控服务PID
                startMs: 分析的开始时间，通过get_current_time工具获取毫秒级时间戳
                endMs: 分析的结束时间，通过get_current_time工具获取毫秒级时间戳
                profileType: Profile类型，用于选择需要分析的Profile指标，支持CPU热点和内存热点，如'cpu'、'memory'
                ip: ARMS应用服务主机地址，非必要参数，用于选择所在的服务机器，如有多个填写时以英文逗号","分隔，如'192.168.0.1,192.168.0.2'，不填写默认查询服务所在的所有IP
                thread: 服务线程名称，非必要参数，用于选择对应线程，如有多个填写时以英文逗号","分隔，如'C1 CompilerThre,C2 CompilerThre'，不填写默认查询服务所有线程
                threadGroup: 服务聚合线程组名称，非必要参数，用于选择对应线程组，如有多个填写时以英文逗号","分隔，如'http-nio-*-exec-*,http-nio-*-ClientPoller-*'，不填写默认查询服务所有聚合线程组
                regionId: 阿里云区域ID，如'cn-hangzhou'、'cn-shanghai'等
            """
            try:
                valid_types = ['cpu', 'memory']
                profileType = profileType.lower()
                if profileType not in valid_types:
                    raise ValueError(f"无效的profileType: {profileType}, 仅支持: {', '.join(valid_types)}")

                # Connect to ARMS client
                arms_client: ArmsClient = ctx.request_context.lifespan_context["arms_client"].with_region(regionId)
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -



src/mcp_server_aliyun_observability/toolkit/arms_toolkit.py [326:360]:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
        ) -> dict:
            """对比两个时间段火焰图的性能变化。

            ## 功能概述

            对应用在两个不同时间段内的性能进行分析，生成差分火焰图。通常用于发布前后或性能优化前后性能对比，帮助识别性能提升或退化。

            ## 使用场景

            - 发布前后、性能优化前后不同时间段火焰图性能对比

            ## 查询示例

            - "帮我分析应用 XXX 在发布前后的性能变化情况"

            Args:
                ctx: MCP上下文，用于访问SLS客户端
                pid: ARMS应用监控服务PID
                currentStartMs: 火焰图当前（基准）时间段的开始时间戳，通过get_current_time工具获取毫秒级时间戳
                currentEndMs: 火焰图当前（基准）时间段的结束时间戳，通过get_current_time工具获取毫秒级时间戳
                referenceStartMs: 火焰图对比时间段（参考时间段）的开始时间戳，通过get_current_time工具获取毫秒级时间戳
                referenceEndMs: 火焰图对比时间段（参考时间段）的结束时间戳，通过get_current_time工具获取毫秒级时间戳
                profileType: Profile类型，如'cpu'、'memory'
                ip: ARMS应用服务主机地址，非必要参数，用于选择所在的服务机器，如有多个填写时以英文逗号","分隔，如'192.168.0.1,192.168.0.2'，不填写默认查询服务所在的所有IP
                thread: 服务线程名称，非必要参数，用于选择对应线程，如有多个填写时以英文逗号","分隔，如'C1 CompilerThre,C2 CompilerThre'，不填写默认查询服务所有线程
                threadGroup: 服务聚合线程组名称，非必要参数，用于选择对应线程组，如有多个填写时以英文逗号","分隔，如'http-nio-*-exec-*,http-nio-*-ClientPoller-*'，不填写默认查询服务所有聚合线程组
                regionId: 阿里云区域ID，如'cn-hangzhou'、'cn-shanghai'等
            """
            try:
                valid_types = ['cpu', 'memory']
                profileType = profileType.lower()
                if profileType not in valid_types:
                    raise ValueError(f"无效的profileType: {profileType}, 仅支持: {', '.join(valid_types)}")

                arms_client: ArmsClient = ctx.request_context.lifespan_context["arms_client"].with_region(regionId)
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -



